Skip to content

Commit 344f7a1

Browse files
authored
Remove Mastodon oEmbed provider registration (#2161)
1 parent 010689b commit 344f7a1

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed

includes/class-activitypub.php

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ public static function init() {
3030
\add_action( 'init', array( self::class, 'theme_compat' ), 11 );
3131
\add_action( 'init', array( self::class, 'register_user_meta' ), 11 );
3232
\add_action( 'init', array( self::class, 'register_post_types' ), 11 );
33-
\add_action( 'init', array( self::class, 'register_oembed_providers' ), 11 );
3433

3534
\add_action( 'rest_api_init', array( self::class, 'register_ap_actor_rest_field' ) );
3635

@@ -907,18 +906,6 @@ public static function default_post_metadata( $meta_value, $object_id, $meta_key
907906
return $meta_value;
908907
}
909908

910-
/**
911-
* Register some Mastodon oEmbed providers.
912-
*/
913-
public static function register_oembed_providers() {
914-
\wp_oembed_add_provider( '#https?://mastodon\.social/(@.+)/([0-9]+)#i', 'https://mastodon.social/api/oembed', true );
915-
\wp_oembed_add_provider( '#https?://mastodon\.online/(@.+)/([0-9]+)#i', 'https://mastodon.online/api/oembed', true );
916-
\wp_oembed_add_provider( '#https?://mastodon\.cloud/(@.+)/([0-9]+)#i', 'https://mastodon.cloud/api/oembed', true );
917-
\wp_oembed_add_provider( '#https?://mstdn\.social/(@.+)/([0-9]+)#i', 'https://mstdn.social/api/oembed', true );
918-
\wp_oembed_add_provider( '#https?://mastodon\.world/(@.+)/([0-9]+)#i', 'https://mastodon.world/api/oembed', true );
919-
\wp_oembed_add_provider( '#https?://mas\.to/(@.+)/([0-9]+)#i', 'https://mas.to/api/oembed', true );
920-
}
921-
922909
/**
923910
* Register user meta.
924911
*/

0 commit comments

Comments
 (0)