code improvements
This commit is contained in:
parent
a1753242f3
commit
25b53887ef
2 changed files with 3 additions and 3 deletions
|
@ -50,7 +50,7 @@ function init() {
|
|||
Health_Check::init();
|
||||
Scheduler::init();
|
||||
}
|
||||
\add_action( 'plugins_loaded', '\Activitypub\init' );
|
||||
\add_action( 'plugins_loaded', __NAMESPACE__ . '\init' );
|
||||
|
||||
/**
|
||||
* Class Autoloader
|
||||
|
@ -143,7 +143,7 @@ function enable_buddypress_features() {
|
|||
require_once \dirname( __FILE__ ) . '/integration/class-buddypress.php';
|
||||
Integration\Buddypress::init();
|
||||
}
|
||||
add_action( 'bp_include', '\Activitypub\enable_buddypress_features' );
|
||||
add_action( 'bp_include', __NAMESPACE__ . '\enable_buddypress_features' );
|
||||
|
||||
/**
|
||||
* `get_plugin_data` wrapper
|
||||
|
|
|
@ -3,7 +3,7 @@ namespace Activitypub\Integration;
|
|||
|
||||
class Buddypress {
|
||||
public static function init() {
|
||||
\add_filter( 'activitypub_json_author_array', array( 'Activitypub\Integration\Buddypress', 'add_user_metadata' ), 11, 2 );
|
||||
\add_filter( 'activitypub_json_author_array', array( self::class, 'add_user_metadata' ), 11, 2 );
|
||||
}
|
||||
|
||||
public static function add_user_metadata( $object, $author_id ) {
|
||||
|
|
Loading…
Reference in a new issue