Ticket #30429: 30429.3.patch
| File 30429.3.patch, 2.1 KB (added by , 10 years ago) |
|---|
-
wp-includes/class-wp-xmlrpc-server.php
1316 1316 } 1317 1317 1318 1318 if ( ! empty( $dateCreated ) ) { 1319 $post_data['post_date'] = get_date_from_gmt( iso8601_to_datetime( $dateCreated ));1320 $post_data['post_date_gmt'] = iso8601_to_datetime( $dateCreated, 'GMT');1319 $post_data['post_date'] = iso8601_to_datetime( $dateCreated ); 1320 $post_data['post_date_gmt'] = get_gmt_from_date( $post_data['post_date'] ); 1321 1321 } 1322 1322 1323 1323 if ( ! isset( $post_data['ID'] ) ) … … 3363 3363 if ( !empty( $content_struct['date_created_gmt'] ) ) { 3364 3364 // We know this is supposed to be GMT, so we're going to slap that Z on there by force 3365 3365 $dateCreated = rtrim( $content_struct['date_created_gmt']->getIso(), 'Z' ) . 'Z'; 3366 $comment_date = get_date_from_gmt(iso8601_to_datetime($dateCreated));3367 $comment_date_gmt = iso8601_to_datetime($dateCreated, 'GMT');3366 $comment_date = iso8601_to_datetime( $dateCreated ); 3367 $comment_date_gmt = get_gmt_from_date( $comment_date ); 3368 3368 } 3369 3369 3370 3370 if ( isset($content_struct['content']) ) … … 4905 4905 $dateCreated = $content_struct['dateCreated']->getIso(); 4906 4906 4907 4907 if ( !empty( $dateCreated ) ) { 4908 $post_date = get_date_from_gmt(iso8601_to_datetime($dateCreated));4909 $post_date_gmt = iso8601_to_datetime($dateCreated, 'GMT');4908 $post_date = iso8601_to_datetime( $dateCreated ); 4909 $post_date_gmt = get_gmt_from_date( $post_date ); 4910 4910 } else { 4911 4911 $post_date = current_time('mysql'); 4912 4912 $post_date_gmt = current_time('mysql', 1); … … 5260 5260 $dateCreated = $content_struct['dateCreated']->getIso(); 5261 5261 5262 5262 if ( !empty( $dateCreated ) ) { 5263 $post_date = get_date_from_gmt(iso8601_to_datetime($dateCreated));5264 $post_date_gmt = iso8601_to_datetime($dateCreated, 'GMT');5263 $post_date = iso8601_to_datetime( $dateCreated ); 5264 $post_date_gmt = get_gmt_from_date( $post_date, 'GMT' ); 5265 5265 } else { 5266 5266 $post_date = $postdata['post_date']; 5267 5267 $post_date_gmt = $postdata['post_date_gmt'];