| @@ 185-194 (lines=10) @@ | ||
| 182 | $this->maxwidth = $maxwidth; |
|
| 183 | ||
| 184 | $data = $this->get_data(); |
|
| 185 | if ( is_wp_error( $data ) || empty( $data ) ) { |
|
| 186 | /** This filter is documented in modules/videopress/class.videopress-player.php */ |
|
| 187 | if ( ! apply_filters( 'jetpack_videopress_use_legacy_player', false ) ) { |
|
| 188 | // Unlike the Flash player, the new player does it's own error checking, age gate, etc. |
|
| 189 | $data = (object) array( 'guid' => $guid, 'width' => $maxwidth, 'height' => $maxwidth / 16 * 9 ); |
|
| 190 | } else { |
|
| 191 | $this->error = $data; |
|
| 192 | return; |
|
| 193 | } |
|
| 194 | } |
|
| 195 | ||
| 196 | if ( isset( $data->blog_id ) ) |
|
| 197 | $this->blog_id = absint( $data->blog_id ); |
|
| @@ 177-186 (lines=10) @@ | ||
| 174 | $this->maxwidth = $maxwidth; |
|
| 175 | ||
| 176 | $data = $this->get_data(); |
|
| 177 | if ( is_wp_error( $data ) || empty( $data ) ) { |
|
| 178 | /** This filter is documented in modules/videopress/class.videopress-player.php */ |
|
| 179 | if ( ! apply_filters( 'jetpack_videopress_use_legacy_player', false ) ) { |
|
| 180 | // Unlike the Flash player, the new player does it's own error checking, age gate, etc. |
|
| 181 | $data = (object) array( 'guid' => $guid, 'width' => $maxwidth, 'height' => $maxwidth / 16 * 9 ); |
|
| 182 | } else { |
|
| 183 | $this->error = $data; |
|
| 184 | return; |
|
| 185 | } |
|
| 186 | } |
|
| 187 | ||
| 188 | if ( isset( $data->blog_id ) ) |
|
| 189 | $this->blog_id = absint( $data->blog_id ); |
|