| @@ -1,10 +1,18 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | namespace Activitypub; |
| 3 | 3 | |
| 4 | 4 | use WP_User_Query; |
| 5 | -use Activitypub\Model\Blog_User; | |
| 5 | +use Activitypub\Model\Blog; | |
| 6 | +use Activitypub\Activitypub; | |
| 7 | +use Activitypub\Collection\Users; | |
| 6 | 8 | |
| 9 | +use function Activitypub\count_followers; | |
| 10 | +use function Activitypub\is_user_disabled; | |
| 11 | +use function Activitypub\was_comment_received; | |
| 12 | +use function Activitypub\is_comment_federatable; | |
| 13 | +use function Activitypub\add_default_actor_extra_fields; | |
| 14 | + | |
| 7 | 15 | /** |
| 8 | 16 | * ActivityPub Admin Class |
| 9 | 17 | * |
| 10 | 18 | * @author Matthias Pfefferle |
| @@ -15,14 +23,32 @@ | ||
| 15 | 23 | */ |
| 16 | 24 | public static function init() { |
| 17 | 25 | \add_action( 'admin_menu', array( self::class, 'admin_menu' ) ); |
| 18 | 26 | \add_action( 'admin_init', array( self::class, 'register_settings' ) ); |
| 27 | + \add_action( 'load-comment.php', array( self::class, 'edit_comment' ) ); | |
| 28 | + \add_action( 'load-post.php', array( self::class, 'edit_post' ) ); | |
| 29 | + \add_action( 'load-edit.php', array( self::class, 'list_posts' ) ); | |
| 19 | 30 | \add_action( 'personal_options_update', array( self::class, 'save_user_description' ) ); |
| 20 | 31 | \add_action( 'admin_enqueue_scripts', array( self::class, 'enqueue_scripts' ) ); |
| 32 | + \add_action( 'admin_notices', array( self::class, 'admin_notices' ) ); | |
| 21 | 33 | |
| 34 | + \add_filter( 'comment_row_actions', array( self::class, 'comment_row_actions' ), 10, 2 ); | |
| 35 | + \add_filter( 'manage_edit-comments_columns', array( static::class, 'manage_comment_columns' ) ); | |
| 36 | + \add_action( 'manage_comments_custom_column', array( static::class, 'manage_comments_custom_column' ), 9, 2 ); | |
| 37 | + | |
| 38 | + \add_filter( 'manage_posts_columns', array( static::class, 'manage_post_columns' ), 10, 2 ); | |
| 39 | + \add_action( 'manage_posts_custom_column', array( self::class, 'manage_posts_custom_column' ), 10, 2 ); | |
| 40 | + | |
| 41 | + \add_filter( 'manage_users_columns', array( self::class, 'manage_users_columns' ), 10, 1 ); | |
| 42 | + \add_action( 'manage_users_custom_column', array( self::class, 'manage_users_custom_column' ), 10, 3 ); | |
| 43 | + \add_filter( 'bulk_actions-users', array( self::class, 'user_bulk_options' ) ); | |
| 44 | + \add_filter( 'handle_bulk_actions-users', array( self::class, 'handle_bulk_request' ), 10, 3 ); | |
| 45 | + | |
| 22 | 46 | if ( ! is_user_disabled( get_current_user_id() ) ) { |
| 23 | 47 | \add_action( 'show_user_profile', array( self::class, 'add_profile' ) ); |
| 24 | 48 | } |
| 49 | + | |
| 50 | + \add_filter( 'dashboard_glance_items', array( self::class, 'dashboard_glance_items' ) ); | |
| 25 | 51 | } |
| 26 | 52 | |
| 27 | 53 | /** |
| 28 | 54 | * Add admin menu entry |
| @@ -42,12 +68,55 @@ | ||
| 42 | 68 | if ( ! is_user_disabled( get_current_user_id() ) ) { |
| 43 | 69 | $followers_list_page = \add_users_page( \__( 'Followers', 'activitypub' ), \__( 'Followers', 'activitypub' ), 'read', 'activitypub-followers-list', array( self::class, 'followers_list_page' ) ); |
| 44 | 70 | |
| 45 | 71 | \add_action( 'load-' . $followers_list_page, array( self::class, 'add_followers_list_help_tab' ) ); |
| 72 | + | |
| 73 | + \add_users_page( \__( 'Extra Fields', 'activitypub' ), \__( 'Extra Fields', 'activitypub' ), 'read', esc_url( admin_url( '/edit.php?post_type=ap_extrafield' ) ) ); | |
| 46 | 74 | } |
| 47 | 75 | } |
| 48 | 76 | |
| 49 | 77 | /** |
| 78 | + * Display admin menu notices about configuration problems or conflicts. | |
| 79 | + * | |
| 80 | + * @return void | |
| 81 | + */ | |
| 82 | + public static function admin_notices() { | |
| 83 | + $permalink_structure = \get_option( 'permalink_structure' ); | |
| 84 | + if ( empty( $permalink_structure ) ) { | |
| 85 | + $admin_notice = \__( 'You are using the ActivityPub plugin with a permalink structure of "plain". This will prevent ActivityPub from working. Please go to "Settings" / "Permalinks" and choose a permalink structure other than "plain".', 'activitypub' ); | |
| 86 | + self::show_admin_notice( $admin_notice, 'error' ); | |
| 87 | + } | |
| 88 | + | |
| 89 | + $current_screen = get_current_screen(); | |
| 90 | + | |
| 91 | + if ( isset( $current_screen->id ) && 'edit-ap_extrafield' === $current_screen->id ) { | |
| 92 | + ?> | |
| 93 | + <div class="notice" style="margin: 0; background: none; border: none; box-shadow: none; padding: 15px 0 0 0; font-size: 14px;"> | |
| 94 | + <?php esc_html_e( 'These are extra fields that are used for your ActivityPub profile. You can use your homepage, social profiles, pronouns, age, anything you want.', 'activitypub' ); ?> | |
| 95 | + </div> | |
| 96 | + <?php | |
| 97 | + } | |
| 98 | + } | |
| 99 | + | |
| 100 | + /** | |
| 101 | + * Display one admin menu notice about configuration problems or conflicts. | |
| 102 | + * | |
| 103 | + * @param string $admin_notice The notice to display. | |
| 104 | + * @param string $level The level of the notice (error, warning, success, info). | |
| 105 | + * | |
| 106 | + * @return void | |
| 107 | + */ | |
| 108 | + private static function show_admin_notice( $admin_notice, $level ) { | |
| 109 | + ?> | |
| 110 | + | |
| 111 | + <div class="notice notice-<?php echo esc_attr( $level ); ?>"> | |
| 112 | + <p><?php echo wp_kses( $admin_notice, 'data' ); ?></p> | |
| 113 | + </div> | |
| 114 | + | |
| 115 | + <?php | |
| 116 | + } | |
| 117 | + | |
| 118 | + /** | |
| 50 | 119 | * Load settings page |
| 51 | 120 | */ |
| 52 | 121 | public static function settings_page() { |
| 53 | 122 | // phpcs:ignore WordPress.Security.NonceVerification.Recommended |
| @@ -136,9 +205,8 @@ | ||
| 136 | 205 | 'show_in_rest' => array( |
| 137 | 206 | 'schema' => array( |
| 138 | 207 | 'enum' => array( |
| 139 | 208 | 'note', |
| 140 | - 'article', | |
| 141 | 209 | 'wordpress-post-format', |
| 142 | 210 | ), |
| 143 | 211 | ), |
| 144 | 212 | ), |
| @@ -160,9 +228,9 @@ | ||
| 160 | 228 | array( |
| 161 | 229 | 'type' => 'string', |
| 162 | 230 | 'description' => \esc_html__( 'Enable ActivityPub support for post types', 'activitypub' ), |
| 163 | 231 | 'show_in_rest' => true, |
| 164 | - 'default' => array( 'post', 'pages' ), | |
| 232 | + 'default' => array( 'post' ), | |
| 165 | 233 | ) |
| 166 | 234 | ); |
| 167 | 235 | \register_setting( |
| 168 | 236 | 'activitypub', |
| @@ -170,10 +238,10 @@ | ||
| 170 | 238 | array( |
| 171 | 239 | 'type' => 'string', |
| 172 | 240 | 'description' => \esc_html__( 'The Identifier of the Blog-User', 'activitypub' ), |
| 173 | 241 | 'show_in_rest' => true, |
| 174 | - 'default' => Blog_User::get_default_username(), | |
| 175 | - 'sanitize_callback' => function( $value ) { | |
| 242 | + 'default' => Blog::get_default_username(), | |
| 243 | + 'sanitize_callback' => function ( $value ) { | |
| 176 | 244 | // hack to allow dots in the username |
| 177 | 245 | $parts = explode( '.', $value ); |
| 178 | 246 | $sanitized = array(); |
| 179 | 247 | |
| @@ -201,9 +269,9 @@ | ||
| 201 | 269 | \esc_html__( 'You cannot use an existing author\'s name for the blog profile ID.', 'activitypub' ), |
| 202 | 270 | 'error' |
| 203 | 271 | ); |
| 204 | 272 | |
| 205 | - return Blog_User::get_default_username(); | |
| 273 | + return Blog::get_default_username(); | |
| 206 | 274 | } |
| 207 | 275 | |
| 208 | 276 | return $sanitized; |
| 209 | 277 | }, |
| @@ -267,9 +335,315 @@ | ||
| 267 | 335 | } |
| 268 | 336 | |
| 269 | 337 | public static function enqueue_scripts( $hook_suffix ) { |
| 270 | 338 | if ( false !== strpos( $hook_suffix, 'activitypub' ) ) { |
| 271 | - wp_enqueue_style( 'activitypub-admin-styles', plugins_url( 'assets/css/activitypub-admin.css', ACTIVITYPUB_PLUGIN_FILE ), array(), '1.0.0' ); | |
| 272 | - wp_enqueue_script( 'activitypub-admin-styles', plugins_url( 'assets/js/activitypub-admin.js', ACTIVITYPUB_PLUGIN_FILE ), array( 'jquery' ), '1.0.0', false ); | |
| 339 | + wp_enqueue_style( 'activitypub-admin-styles', plugins_url( 'assets/css/activitypub-admin.css', ACTIVITYPUB_PLUGIN_FILE ), array(), get_plugin_version() ); | |
| 340 | + wp_enqueue_script( 'activitypub-admin-script', plugins_url( 'assets/js/activitypub-admin.js', ACTIVITYPUB_PLUGIN_FILE ), array( 'jquery' ), get_plugin_version(), false ); | |
| 273 | 341 | } |
| 342 | + | |
| 343 | + if ( 'index.php' === $hook_suffix ) { | |
| 344 | + wp_enqueue_style( 'activitypub-admin-styles', plugins_url( 'assets/css/activitypub-admin.css', ACTIVITYPUB_PLUGIN_FILE ), array(), get_plugin_version() ); | |
| 345 | + } | |
| 346 | + } | |
| 347 | + | |
| 348 | + /** | |
| 349 | + * Hook into the edit_comment functionality | |
| 350 | + * | |
| 351 | + * * Disable the edit_comment capability for federated comments. | |
| 352 | + * | |
| 353 | + * @return void | |
| 354 | + */ | |
| 355 | + public static function edit_comment() { | |
| 356 | + // Disable the edit_comment capability for federated comments. | |
| 357 | + \add_filter( | |
| 358 | + 'user_has_cap', | |
| 359 | + function ( $allcaps, $caps, $arg ) { | |
| 360 | + if ( 'edit_comment' !== $arg[0] ) { | |
| 361 | + return $allcaps; | |
| 362 | + } | |
| 363 | + | |
| 364 | + if ( was_comment_received( $arg[2] ) ) { | |
| 365 | + return false; | |
| 366 | + } | |
| 367 | + | |
| 368 | + return $allcaps; | |
| 369 | + }, | |
| 370 | + 1, | |
| 371 | + 3 | |
| 372 | + ); | |
| 373 | + } | |
| 374 | + | |
| 375 | + public static function edit_post() { | |
| 376 | + // Disable the edit_post capability for federated posts. | |
| 377 | + \add_filter( | |
| 378 | + 'user_has_cap', | |
| 379 | + function ( $allcaps, $caps, $arg ) { | |
| 380 | + if ( 'edit_post' !== $arg[0] ) { | |
| 381 | + return $allcaps; | |
| 382 | + } | |
| 383 | + | |
| 384 | + $post = get_post( $arg[2] ); | |
| 385 | + | |
| 386 | + if ( 'ap_extrafield' !== $post->post_type ) { | |
| 387 | + return $allcaps; | |
| 388 | + } | |
| 389 | + | |
| 390 | + if ( (int) get_current_user_id() !== (int) $post->post_author ) { | |
| 391 | + return false; | |
| 392 | + } | |
| 393 | + | |
| 394 | + return $allcaps; | |
| 395 | + }, | |
| 396 | + 1, | |
| 397 | + 3 | |
| 398 | + ); | |
| 399 | + } | |
| 400 | + | |
| 401 | + /** | |
| 402 | + * Add ActivityPub specific actions/filters to the post list view | |
| 403 | + * | |
| 404 | + * @return void | |
| 405 | + */ | |
| 406 | + public static function list_posts() { | |
| 407 | + // Show only the user's extra fields. | |
| 408 | + \add_action( | |
| 409 | + 'pre_get_posts', | |
| 410 | + function ( $query ) { | |
| 411 | + if ( $query->get( 'post_type' ) === 'ap_extrafield' ) { | |
| 412 | + $query->set( 'author', get_current_user_id() ); | |
| 413 | + } | |
| 414 | + } | |
| 415 | + ); | |
| 416 | + | |
| 417 | + // Remove all views for the extra fields. | |
| 418 | + $screen_id = get_current_screen()->id; | |
| 419 | + | |
| 420 | + add_filter( | |
| 421 | + "views_{$screen_id}", | |
| 422 | + function ( $views ) { | |
| 423 | + if ( 'ap_extrafield' === get_post_type() ) { | |
| 424 | + return array(); | |
| 425 | + } | |
| 426 | + | |
| 427 | + return $views; | |
| 428 | + } | |
| 429 | + ); | |
| 430 | + | |
| 431 | + // Set defaults for new extra fields. | |
| 432 | + if ( 'edit-ap_extrafield' === $screen_id ) { | |
| 433 | + Activitypub::default_actor_extra_fields( array(), get_current_user_id() ); | |
| 434 | + } | |
| 435 | + } | |
| 436 | + | |
| 437 | + public static function comment_row_actions( $actions, $comment ) { | |
| 438 | + if ( was_comment_received( $comment ) ) { | |
| 439 | + unset( $actions['edit'] ); | |
| 440 | + unset( $actions['quickedit'] ); | |
| 441 | + } | |
| 442 | + | |
| 443 | + return $actions; | |
| 444 | + } | |
| 445 | + | |
| 446 | + /** | |
| 447 | + * Add a column "activitypub" | |
| 448 | + * | |
| 449 | + * This column shows if the user has the capability to use ActivityPub. | |
| 450 | + * | |
| 451 | + * @param array $columns The columns. | |
| 452 | + * | |
| 453 | + * @return array The columns extended by the activitypub. | |
| 454 | + */ | |
| 455 | + public static function manage_users_columns( $columns ) { | |
| 456 | + $columns['activitypub'] = __( 'ActivityPub', 'activitypub' ); | |
| 457 | + return $columns; | |
| 458 | + } | |
| 459 | + | |
| 460 | + /** | |
| 461 | + * Add "comment-type" and "protocol" as column in WP-Admin | |
| 462 | + * | |
| 463 | + * @param array $columns the list of column names | |
| 464 | + */ | |
| 465 | + public static function manage_comment_columns( $columns ) { | |
| 466 | + $columns['comment_type'] = esc_attr__( 'Comment-Type', 'activitypub' ); | |
| 467 | + $columns['comment_protocol'] = esc_attr__( 'Protocol', 'activitypub' ); | |
| 468 | + | |
| 469 | + return $columns; | |
| 470 | + } | |
| 471 | + | |
| 472 | + /** | |
| 473 | + * Add "post_content" as column for Extra-Fields in WP-Admin | |
| 474 | + * | |
| 475 | + * @param array $columns Tthe list of column names. | |
| 476 | + * @param string $post_type The post type. | |
| 477 | + */ | |
| 478 | + public static function manage_post_columns( $columns, $post_type ) { | |
| 479 | + if ( 'ap_extrafield' === $post_type ) { | |
| 480 | + $after_key = 'title'; | |
| 481 | + $index = array_search( $after_key, array_keys( $columns ), true ); | |
| 482 | + $columns = array_slice( $columns, 0, $index + 1 ) + array( 'extra_field_content' => esc_attr__( 'Content', 'activitypub' ) ) + $columns; | |
| 483 | + } | |
| 484 | + | |
| 485 | + return $columns; | |
| 486 | + } | |
| 487 | + | |
| 488 | + /** | |
| 489 | + * Add "comment-type" and "protocol" as column in WP-Admin | |
| 490 | + * | |
| 491 | + * @param array $column The column to implement | |
| 492 | + * @param int $comment_id The comment id | |
| 493 | + */ | |
| 494 | + public static function manage_comments_custom_column( $column, $comment_id ) { | |
| 495 | + if ( 'comment_type' === $column && ! defined( 'WEBMENTION_PLUGIN_DIR' ) ) { | |
| 496 | + echo esc_attr( ucfirst( get_comment_type( $comment_id ) ) ); | |
| 497 | + } elseif ( 'comment_protocol' === $column ) { | |
| 498 | + $protocol = get_comment_meta( $comment_id, 'protocol', true ); | |
| 499 | + | |
| 500 | + if ( $protocol ) { | |
| 501 | + echo esc_attr( ucfirst( str_replace( 'activitypub', 'ActivityPub', $protocol ) ) ); | |
| 502 | + } else { | |
| 503 | + esc_attr_e( 'Local', 'activitypub' ); | |
| 504 | + } | |
| 505 | + } | |
| 506 | + } | |
| 507 | + | |
| 508 | + /** | |
| 509 | + * Return the results for the activitypub column. | |
| 510 | + * | |
| 511 | + * @param string $output Custom column output. Default empty. | |
| 512 | + * @param string $column_name Column name. | |
| 513 | + * @param int $user_id ID of the currently-listed user. | |
| 514 | + * | |
| 515 | + * @return string The column contents. | |
| 516 | + */ | |
| 517 | + public static function manage_users_custom_column( $output, $column_name, $user_id ) { | |
| 518 | + if ( 'activitypub' !== $column_name ) { | |
| 519 | + return $output; | |
| 520 | + } | |
| 521 | + | |
| 522 | + if ( \user_can( $user_id, 'activitypub' ) ) { | |
| 523 | + return '<span aria-hidden="true">✓</span><span class="screen-reader-text">' . esc_html__( 'ActivityPub enabled for this author', 'activitypub' ) . '</span>'; | |
| 524 | + } else { | |
| 525 | + return '<span aria-hidden="true">✗</span><span class="screen-reader-text">' . esc_html__( 'ActivityPub disabled for this author', 'activitypub' ) . '</span>'; | |
| 526 | + } | |
| 527 | + } | |
| 528 | + | |
| 529 | + /** | |
| 530 | + * Add a column "extra_field_content" to the post list view | |
| 531 | + * | |
| 532 | + * @param string $column_name The column name. | |
| 533 | + * @param int $post_id The post ID. | |
| 534 | + * | |
| 535 | + * @return void | |
| 536 | + */ | |
| 537 | + public static function manage_posts_custom_column( $column_name, $post_id ) { | |
| 538 | + $post = get_post( $post_id ); | |
| 539 | + | |
| 540 | + if ( 'extra_field_content' === $column_name ) { | |
| 541 | + $post = get_post( $post_id ); | |
| 542 | + if ( 'ap_extrafield' === $post->post_type ) { | |
| 543 | + echo esc_attr( wp_strip_all_tags( $post->post_content ) ); | |
| 544 | + } | |
| 545 | + } | |
| 546 | + } | |
| 547 | + | |
| 548 | + /** | |
| 549 | + * Add options to the Bulk dropdown on the users page | |
| 550 | + * | |
| 551 | + * @param array $actions The existing bulk options. | |
| 552 | + * | |
| 553 | + * @return array The extended bulk options. | |
| 554 | + */ | |
| 555 | + public static function user_bulk_options( $actions ) { | |
| 556 | + $actions['add_activitypub_cap'] = __( 'Enable for ActivityPub', 'activitypub' ); | |
| 557 | + $actions['remove_activitypub_cap'] = __( 'Disable for ActivityPub', 'activitypub' ); | |
| 558 | + | |
| 559 | + return $actions; | |
| 560 | + } | |
| 561 | + | |
| 562 | + /** | |
| 563 | + * Handle bulk activitypub requests | |
| 564 | + * | |
| 565 | + * * `add_activitypub_cap` - Add the activitypub capability to the selected users. | |
| 566 | + * * `remove_activitypub_cap` - Remove the activitypub capability from the selected users. | |
| 567 | + * | |
| 568 | + * @param string $sendback The URL to send the user back to. | |
| 569 | + * @param string $action The requested action. | |
| 570 | + * @param array $users The selected users. | |
| 571 | + * | |
| 572 | + * @return string The URL to send the user back to. | |
| 573 | + */ | |
| 574 | + public static function handle_bulk_request( $sendback, $action, $users ) { | |
| 575 | + if ( | |
| 576 | + 'remove_activitypub_cap' !== $action && | |
| 577 | + 'add_activitypub_cap' !== $action | |
| 578 | + ) { | |
| 579 | + return $sendback; | |
| 580 | + } | |
| 581 | + | |
| 582 | + foreach ( $users as $user_id ) { | |
| 583 | + $user = new \WP_User( $user_id ); | |
| 584 | + if ( | |
| 585 | + 'add_activitypub_cap' === $action && | |
| 586 | + user_can( $user_id, 'publish_posts' ) | |
| 587 | + ) { | |
| 588 | + $user->add_cap( 'activitypub' ); | |
| 589 | + } elseif ( 'remove_activitypub_cap' === $action ) { | |
| 590 | + $user->remove_cap( 'activitypub' ); | |
| 591 | + } | |
| 592 | + } | |
| 593 | + | |
| 594 | + return $sendback; | |
| 595 | + } | |
| 596 | + | |
| 597 | + /** | |
| 598 | + * Add ActivityPub infos to the dashboard glance items | |
| 599 | + * | |
| 600 | + * @param array $items The existing glance items. | |
| 601 | + * | |
| 602 | + * @return array The extended glance items. | |
| 603 | + */ | |
| 604 | + public static function dashboard_glance_items( $items ) { | |
| 605 | + \add_filter( 'number_format_i18n', '\Activitypub\custom_large_numbers', 10, 3 ); | |
| 606 | + | |
| 607 | + if ( ! is_user_disabled( get_current_user_id() ) ) { | |
| 608 | + $follower_count = sprintf( | |
| 609 | + // translators: %s: number of followers | |
| 610 | + _n( | |
| 611 | + '%s Follower', | |
| 612 | + '%s Followers', | |
| 613 | + count_followers( \get_current_user_id() ), | |
| 614 | + 'activitypub' | |
| 615 | + ), | |
| 616 | + \number_format_i18n( count_followers( \get_current_user_id() ) ) | |
| 617 | + ); | |
| 618 | + $items['activitypub-followers-user'] = sprintf( | |
| 619 | + '<a class="activitypub-followers" href="%1$s" title="%2$s">%3$s</a>', | |
| 620 | + \esc_url( \admin_url( 'users.php?page=activitypub-followers-list' ) ), | |
| 621 | + \esc_attr__( 'Your followers', 'activitypub' ), | |
| 622 | + \esc_html( $follower_count ) | |
| 623 | + ); | |
| 624 | + } | |
| 625 | + | |
| 626 | + if ( ! is_user_type_disabled( 'blog' ) && current_user_can( 'manage_options' ) ) { | |
| 627 | + $follower_count = sprintf( | |
| 628 | + // translators: %s: number of followers | |
| 629 | + _n( | |
| 630 | + '%s Follower (Blog)', | |
| 631 | + '%s Followers (Blog)', | |
| 632 | + count_followers( Users::BLOG_USER_ID ), | |
| 633 | + 'activitypub' | |
| 634 | + ), | |
| 635 | + \number_format_i18n( count_followers( Users::BLOG_USER_ID ) ) | |
| 636 | + ); | |
| 637 | + $items['activitypub-followers-blog'] = sprintf( | |
| 638 | + '<a class="activitypub-followers" href="%1$s" title="%2$s">%3$s</a>', | |
| 639 | + \esc_url( \admin_url( 'options-general.php?page=activitypub&tab=followers' ) ), | |
| 640 | + \esc_attr__( 'The Blog\'s followers', 'activitypub' ), | |
| 641 | + \esc_html( $follower_count ) | |
| 642 | + ); | |
| 643 | + } | |
| 644 | + | |
| 645 | + \remove_filter( 'number_format_i18n', '\Activitypub\custom_large_numbers', 10, 3 ); | |
| 646 | + | |
| 647 | + return $items; | |
| 274 | 648 | } |
| 275 | 649 | } |