Revisions: correct a timezone display issue.

When preparing the data for the revisions screen, add ' +0000' to the gmt date string before passing it thru `strtotime`.

Props biranit, nacin, buley.
Fixes #25365.


git-svn-id: https://develop.svn.wordpress.org/trunk@41559 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Adam Silverstein 2017-09-21 23:32:25 +00:00
parent a91d3980df
commit e92db998d2

View File

@ -166,7 +166,7 @@ function wp_prepare_revisions_for_js( $post, $selected_revision_id, $from = null
foreach ( $revisions as $revision ) {
$modified = strtotime( $revision->post_modified );
$modified_gmt = strtotime( $revision->post_modified_gmt );
$modified_gmt = strtotime( $revision->post_modified_gmt . ' +0000' );
if ( $can_restore ) {
$restore_link = str_replace( '&', '&', wp_nonce_url(
add_query_arg(