diff --git a/src/wp-admin/includes/class-wp-community-events.php b/src/wp-admin/includes/class-wp-community-events.php index a3c146cd500fa..129789d8ef70b 100644 --- a/src/wp-admin/includes/class-wp-community-events.php +++ b/src/wp-admin/includes/class-wp-community-events.php @@ -389,7 +389,7 @@ protected function format_event_data_time( $response_body ) { if ( isset( $response_body['events'] ) ) { foreach ( $response_body['events'] as $key => $event ) { - $timestamp = ( new DateTimeImmutable( $el["date"] ) )->getTimestamp(); + $timestamp = ( new DateTimeImmutable( $el['date'] ) )->getTimestamp(); /* * The `date_format` option is not used because it's important diff --git a/src/wp-admin/includes/export.php b/src/wp-admin/includes/export.php index 49f8a7e58152c..5aadde69f290d 100644 --- a/src/wp-admin/includes/export.php +++ b/src/wp-admin/includes/export.php @@ -137,7 +137,7 @@ function export_wp( $args = array() ) { } if ( $args['end_date'] ) { - $where .= $wpdb->prepare( " AND {$wpdb->posts}.post_date < %s", gmdate('Y-m-d', ( new DateTimeImmutable( $args['end_date'] ) )->add( new DateInterval( 'P1M' ) )->getTimestamp() ) ); + $where .= $wpdb->prepare( " AND {$wpdb->posts}.post_date < %s", gmdate( 'Y-m-d', ( new DateTimeImmutable( $args['end_date'] ) )->add( new DateInterval( 'P1M' ) )->getTimestamp() ) ); } } diff --git a/src/wp-includes/class-wp-customize-manager.php b/src/wp-includes/class-wp-customize-manager.php index b9869a267e0c7..1b493cbf5baba 100644 --- a/src/wp-includes/class-wp-customize-manager.php +++ b/src/wp-includes/class-wp-customize-manager.php @@ -2503,7 +2503,7 @@ public function save() { } else { try { $timestamp = ( new DateTimeImmutable( $changeset_date ) )->getTimestamp(); - }catch( \Exception $exception ){ + } catch ( \Exception $exception ) { $timestamp = false; } if ( ! $timestamp ) { diff --git a/src/wp-includes/class-wp.php b/src/wp-includes/class-wp.php index 544c90cb1e043..11a6ea1e41ba2 100644 --- a/src/wp-includes/class-wp.php +++ b/src/wp-includes/class-wp.php @@ -491,7 +491,7 @@ public function send_headers() { $wp_last_modified_post = mysql2date( $date_format, get_lastpostmodified( 'GMT' ), false ); $wp_last_modified_comment = mysql2date( $date_format, get_lastcommentmodified( 'GMT' ), false ); - if ( ( new DateTimeImmutable( $wp_last_modified_post ) )->getTimestamp() > ( new DateTimeImmutable( $wp_last_modified_comment ) )->getTimestamp() ) { + if ( ( new DateTimeImmutable( $wp_last_modified_post ) )->getTimestamp() > ( new DateTimeImmutable( $wp_last_modified_comment ) )->getTimestamp() ) { $wp_last_modified = $wp_last_modified_post; } else { $wp_last_modified = $wp_last_modified_comment; diff --git a/src/wp-includes/post.php b/src/wp-includes/post.php index 5b83a9a76d05a..ce921eabb4c2c 100644 --- a/src/wp-includes/post.php +++ b/src/wp-includes/post.php @@ -5260,7 +5260,7 @@ function check_and_publish_future_post( $post ) { return; } - $time = ( new DateTimeImmutable( $post->post_date_gmt . ' GMT' ) )->getTimestamp(); + $time = ( new DateTimeImmutable( $post->post_date_gmt . ' GMT' ) )->getTimestamp(); // Uh oh, someone jumped the gun! if ( $time > time() ) {