Skip to content

Commit cdb6a05

Browse files
authored
Fix fatal error when Remote_Actors::get_actor() encounters WP_Error (#2676)
1 parent 50ed13a commit cdb6a05

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Significance: patch
2+
Type: fixed
3+
4+
Fix fatal error when displaying posts with mentions of invalid remote actors.

includes/collection/class-remote-actors.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -471,6 +471,8 @@ public static function get_actor( $post ) {
471471

472472
if ( \is_wp_error( $actor ) ) {
473473
self::add_error( $post->ID, $actor );
474+
475+
return $actor;
474476
}
475477

476478
if ( ! $actor->get_webfinger() ) {

0 commit comments

Comments
 (0)