Make WordPress Core


Ignore:
Timestamp:
04/30/2024 09:31:41 AM (14 months ago)
Author:
swissspidy
Message:

REST API: allow overriding excerpt length.

This can be used by the excerpt block in the editor to change the excerpt length without filtering excerpt_length in a conflicting way. This enhancement still needs a corresponding change on the Gutenberg side.

Props swissspidy, antonvlasenko, mukesh27, azaozz, andraganescu, timothyblynjacobs.
Fixes #59043.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/rest-api/wpRestMenuItemsController.php

    r56746 r58065  
    157157        $data     = $response->get_data();
    158158        $keys     = array_keys( $data['endpoints'][0]['args'] );
    159         sort( $keys );
    160         $this->assertSame( array( 'context', 'id' ), $keys );
     159        $this->assertEqualSets( array( 'context', 'id' ), $keys );
    161160    }
    162161
Note: See TracChangeset for help on using the changeset viewer.