| @@ -45,28 +45,20 @@ | ||
| 45 | 45 | /** |
| 46 | 46 | * Load all available Jetpack shortcode files. |
| 47 | 47 | */ |
| 48 | 48 | function jetpack_load_shortcodes() { |
| 49 | - // Prevent third-party shortcode plugins when loading shortcode files. | |
| 50 | - // Format: shortcode => condition_when_to_skip | |
| 51 | - $shortcode_skips = array( | |
| 52 | - 'soundcloud' => function_exists( 'soundcloud_shortcode' ), // SoundCloud Shortcodes plugin | |
| 53 | - ); | |
| 54 | - | |
| 55 | 49 | $shortcode_includes = array(); |
| 56 | 50 | |
| 57 | 51 | foreach ( Jetpack::glob_php( __DIR__ . '/shortcodes' ) as $file ) { |
| 58 | 52 | $filename = substr( basename( $file ), 0, -4 ); |
| 59 | 53 | |
| 60 | - if ( empty( $shortcode_skips[ $filename ] ) ) { | |
| 61 | - $shortcode_includes[ $filename ] = $file; | |
| 62 | - } | |
| 54 | + $shortcode_includes[ $filename ] = $file; | |
| 63 | 55 | } |
| 64 | 56 | |
| 65 | 57 | /** |
| 66 | 58 | * This filter allows other plugins to override which shortcodes Jetpack loads. |
| 67 | 59 | * |
| 68 | - * Fires as part of the `after_setup_theme` WP hook, so modifying code needs to be in a plugin, not in a theme's functions.php. | |
| 60 | + * Fires as part of the `plugins_loaded` WP hook, so modifying code needs to be in a plugin, not in a theme's functions.php. | |
| 69 | 61 | * |
| 70 | 62 | * @module shortcodes |
| 71 | 63 | * |
| 72 | 64 | * @since 2.2.1 |