Skip to content

Commit

Permalink
Small optimization.
Browse files Browse the repository at this point in the history
  • Loading branch information
anton-vlasenko authored and Anton Vlasenko committed Jun 4, 2024
1 parent 8568cda commit f8de6e7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/phpunit/tests/rest-api/rest-schema-setup.php
Original file line number Diff line number Diff line change
Expand Up @@ -759,9 +759,9 @@ private function normalize_fixture( $data, $path ) {
return $data;
}

foreach ( $data as $key => $value ) {
$datetime_keys = array( 'date', 'date_gmt', 'modified', 'modified_gmt' );
$datetime_keys = array( 'date', 'date_gmt', 'modified', 'modified_gmt' );

foreach ( $data as $key => $value ) {
if ( is_string( $value ) ) {
if ( in_array( $key, $datetime_keys, true ) ) {
$data[ $key ] = '2017-02-14T00:00:00';
Expand Down

0 comments on commit f8de6e7

Please sign in to comment.