fix wrong function names
This commit is contained in:
parent
64d2d2995b
commit
81d0e09f6e
2 changed files with 4 additions and 4 deletions
|
@ -78,9 +78,9 @@ class Activity_Dispatcher {
|
||||||
$wp_post->post_author = Users::BLOG_USER_ID;
|
$wp_post->post_author = Users::BLOG_USER_ID;
|
||||||
|
|
||||||
if ( is_single_user() ) {
|
if ( is_single_user() ) {
|
||||||
self::send_user_activity( $wp_post, $type );
|
self::send_activity( $wp_post, $type );
|
||||||
} else {
|
} else {
|
||||||
self::send_announce_activity( $wp_post, $type );
|
self::send_announce( $wp_post, $type );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -34,7 +34,7 @@ class Test_Activitypub_Activity_Dispatcher extends ActivityPub_TestCase_Cache_HT
|
||||||
$pre_http_request = new MockAction();
|
$pre_http_request = new MockAction();
|
||||||
add_filter( 'pre_http_request', array( $pre_http_request, 'filter' ), 10, 3 );
|
add_filter( 'pre_http_request', array( $pre_http_request, 'filter' ), 10, 3 );
|
||||||
|
|
||||||
\Activitypub\Activity_Dispatcher::send_user_activity( get_post( $post ), 'Create' );
|
\Activitypub\Activity_Dispatcher::send_activity( get_post( $post ), 'Create' );
|
||||||
|
|
||||||
$this->assertSame( 2, $pre_http_request->get_call_count() );
|
$this->assertSame( 2, $pre_http_request->get_call_count() );
|
||||||
$all_args = $pre_http_request->get_args();
|
$all_args = $pre_http_request->get_args();
|
||||||
|
@ -74,7 +74,7 @@ class Test_Activitypub_Activity_Dispatcher extends ActivityPub_TestCase_Cache_HT
|
||||||
$pre_http_request = new MockAction();
|
$pre_http_request = new MockAction();
|
||||||
add_filter( 'pre_http_request', array( $pre_http_request, 'filter' ), 10, 3 );
|
add_filter( 'pre_http_request', array( $pre_http_request, 'filter' ), 10, 3 );
|
||||||
|
|
||||||
\Activitypub\Activity_Dispatcher::send_user_activity( get_post( $post ), 'Create' );
|
\Activitypub\Activity_Dispatcher::send_activity( get_post( $post ), 'Create' );
|
||||||
|
|
||||||
$this->assertSame( 1, $pre_http_request->get_call_count() );
|
$this->assertSame( 1, $pre_http_request->get_call_count() );
|
||||||
$all_args = $pre_http_request->get_args();
|
$all_args = $pre_http_request->get_args();
|
||||||
|
|
Loading…
Reference in a new issue