Merge branch 'master' of https://github.com/pfefferle/wordpress-activitypub
This commit is contained in:
commit
57c33e5078
2 changed files with 2 additions and 8 deletions
|
@ -116,6 +116,8 @@ function add_rewrite_rules() {
|
||||||
\add_rewrite_rule( '^.well-known/nodeinfo', 'index.php?rest_route=/activitypub/1.0/nodeinfo/discovery', 'top' );
|
\add_rewrite_rule( '^.well-known/nodeinfo', 'index.php?rest_route=/activitypub/1.0/nodeinfo/discovery', 'top' );
|
||||||
\add_rewrite_rule( '^.well-known/x-nodeinfo2', 'index.php?rest_route=/activitypub/1.0/nodeinfo2', 'top' );
|
\add_rewrite_rule( '^.well-known/x-nodeinfo2', 'index.php?rest_route=/activitypub/1.0/nodeinfo2', 'top' );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
\add_rewrite_endpoint( 'activitypub', EP_AUTHORS | EP_PERMALINK | EP_PAGES );
|
||||||
}
|
}
|
||||||
\add_action( 'init', '\Activitypub\add_rewrite_rules', 1 );
|
\add_action( 'init', '\Activitypub\add_rewrite_rules', 1 );
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,6 @@ class Activitypub {
|
||||||
public static function init() {
|
public static function init() {
|
||||||
\add_filter( 'template_include', array( '\Activitypub\Activitypub', 'render_json_template' ), 99 );
|
\add_filter( 'template_include', array( '\Activitypub\Activitypub', 'render_json_template' ), 99 );
|
||||||
\add_filter( 'query_vars', array( '\Activitypub\Activitypub', 'add_query_vars' ) );
|
\add_filter( 'query_vars', array( '\Activitypub\Activitypub', 'add_query_vars' ) );
|
||||||
\add_action( 'init', array( '\Activitypub\Activitypub', 'add_rewrite_endpoint' ) );
|
|
||||||
\add_filter( 'pre_get_avatar_data', array( '\Activitypub\Activitypub', 'pre_get_avatar_data' ), 11, 2 );
|
\add_filter( 'pre_get_avatar_data', array( '\Activitypub\Activitypub', 'pre_get_avatar_data' ), 11, 2 );
|
||||||
|
|
||||||
// Add support for ActivityPub to custom post types
|
// Add support for ActivityPub to custom post types
|
||||||
|
@ -96,13 +95,6 @@ class Activitypub {
|
||||||
return $vars;
|
return $vars;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Add our rewrite endpoint to permalinks and pages.
|
|
||||||
*/
|
|
||||||
public static function add_rewrite_endpoint() {
|
|
||||||
\add_rewrite_endpoint( 'activitypub', EP_AUTHORS | EP_PERMALINK | EP_PAGES );
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Schedule Activities.
|
* Schedule Activities.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in a new issue