Ticket #16985: 16985.2.patch
File 16985.2.patch, 1.4 KB (added by , 14 years ago) |
---|
-
wp-includes/class-wp-xmlrpc-server.php
2287 2287 if ( !empty( $dateCreated ) ) { 2288 2288 $post_date = get_date_from_gmt(iso8601_to_datetime($dateCreated)); 2289 2289 $post_date_gmt = iso8601_to_datetime($dateCreated, 'GMT'); 2290 } else {2291 $post_date = current_time('mysql');2292 $post_date_gmt = current_time('mysql', 1);2293 2290 } 2294 2291 2295 2292 $post_category = array(); … … 2691 2688 $post_date_gmt = mysql2date('Ymd\TH:i:s', $postdata['post_date_gmt'], false); 2692 2689 2693 2690 // For drafts use the GMT version of the post date 2694 if ( $postdata['post_status'] == 'draft' )2691 if ( $entry['post_status'] == 'draft' && strcmp($post_date_gmt, '19700101T00:00:00') !=0 ) 2695 2692 $post_date_gmt = get_gmt_from_date( mysql2date( 'Y-m-d H:i:s', $postdata['post_date'] ), 'Ymd\TH:i:s' ); 2696 2693 2697 2694 $categories = array(); … … 2817 2814 $post_date_gmt = mysql2date('Ymd\TH:i:s', $entry['post_date_gmt'], false); 2818 2815 2819 2816 // For drafts use the GMT version of the date 2820 if ( $entry['post_status'] == 'draft' )2817 if ( $entry['post_status'] == 'draft' && strcmp($post_date_gmt, '19700101T00:00:00') !=0 ) 2821 2818 $post_date_gmt = get_gmt_from_date( mysql2date( 'Y-m-d H:i:s', $entry['post_date'] ), 'Ymd\TH:i:s' ); 2822 2819 2823 2820 $categories = array();