PluginProbe
Jetpack – WP Security, Backup, Speed, & Growth / 16.2
Jetpack – WP Security, Backup, Speed, & Growth v16.2
16.3-a.1 16.2 16.2-beta 12.0.3 12.1.3 12.2.3 12.3.2 12.4.2 12.5.2 12.6.4 12.7.3 12.8.3 12.9.5 13.0.2 13.1.5 13.2.4 13.3.3 13.4.5 13.5.2 13.6.2 13.7.2 13.8.3 13.9.2 14.0.1 14.1.1 All 503 releases
← All changes | modules/shortcodes/vr.php +6 -2 12.7.316.2 View file →
@@ -5,8 +5,12 @@
5 5 *
6 6 * @package automattic/jetpack
7 7 */
8 8
9 +if ( ! defined( 'ABSPATH' ) ) {
10 + exit( 0 );
11 +}
12 +
9 13 /**
10 14 * Scrub URL paramaters for VR viewer
11 15 *
12 16 * @param array $params {
@@ -83,9 +87,9 @@
83 87 $iframe = add_query_arg( $url_params, 'https://vr.me.sh/view/' );
84 88
85 89 // set some defaults.
86 90 $maxwidth = ( is_numeric( $content_width ) && $content_width > 0 ) ? $content_width : 720;
87 - $view = ( isset( $url_params['view'] ) ) ? $url_params['view'] : 'cinema';
91 + $view = $url_params['view'] ?? 'cinema';
88 92
89 93 // If the shortcode is displayed in a WPCOM notification, display a simple link only.
90 94 if ( defined( 'IS_WPCOM' ) && IS_WPCOM ) {
91 95 require_once WP_CONTENT_DIR . '/lib/display-context.php';
@@ -121,9 +125,9 @@
121 125 * </div>
122 126 *
123 127 * @param array $atts Shortcode attributes.
124 128 *
125 - * @return html - complete vr viewer html
129 + * @return string complete vr viewer html
126 130 */
127 131 function jetpack_vr_viewer_shortcode( $atts ) {
128 132 $params = shortcode_atts(
129 133 array(