Skip to content

Commit

Permalink
fix: prevent coauthor filter on rest request
Browse files Browse the repository at this point in the history
  • Loading branch information
chickenn00dle committed Feb 13, 2024
1 parent e3ced13 commit af5cafc
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public static function filter_coauthors( $coauthors, $post_id ) {
}

// We don't want to filter authors on admin, as it might break things.
if ( is_admin() ) {
if ( is_admin() || defined( 'REST_REQUEST' ) && REST_REQUEST ) {
return $coauthors;
}

Expand Down

0 comments on commit af5cafc

Please sign in to comment.