Skip to content

Commit

Permalink
wpcom wants anonymous functions like this (#901)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattwiebe authored Sep 25, 2024
1 parent 62e7a2b commit b469c23
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions includes/collection/class-extra-fields.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public static function fields_to_attachments( $fields ) {
$attachments = array();
\add_filter(
'activitypub_link_rel',
function( $rel ) {
function ( $rel ) {
$rel .= ' me';

return $rel;
Expand Down Expand Up @@ -187,7 +187,7 @@ public static function default_actor_extra_fields( $extra_fields, $user_id ) {

\add_filter(
'activitypub_link_rel',
function( $rel ) {
function ( $rel ) {
$rel .= ' me';

return $rel;
Expand Down
4 changes: 2 additions & 2 deletions integration/load.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ function plugin_init() {
add_filter(
'activitypub_transformer',
// phpcs:ignore Universal.NamingConventions.NoReservedKeywordParameterNames.objectFound
function( $transformer, $object, $object_class ) {
function ( $transformer, $object, $object_class ) {
if (
'WP_Post' === $object_class &&
\get_post_meta( $object->ID, 'audio_file', true )
Expand Down Expand Up @@ -126,7 +126,7 @@ function register_stream_connector( $classes ) {
// Excluded ActivityPub post types from the Stream.
add_filter(
'wp_stream_posts_exclude_post_types',
function( $post_types ) {
function ( $post_types ) {
$post_types[] = 'ap_follower';
$post_types[] = 'ap_extrafield';
$post_types[] = 'ap_extrafield_blog';
Expand Down

0 comments on commit b469c23

Please sign in to comment.