mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 20:30:23 +00:00
Port autosave to jquery. Props rmccue. see #3824
git-svn-id: https://develop.svn.wordpress.org/trunk@6546 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1002,11 +1002,15 @@ function wp_insert_post($postarr = array()) {
|
||||
if (empty($post_date)) {
|
||||
if ( !in_array($post_status, array('draft', 'pending')) )
|
||||
$post_date = current_time('mysql');
|
||||
else
|
||||
$post_date = '0000-00-00 00:00:00';
|
||||
}
|
||||
|
||||
if (empty($post_date_gmt)) {
|
||||
if ( !in_array($post_status, array('draft', 'pending')) )
|
||||
$post_date_gmt = get_gmt_from_date($post_date);
|
||||
else
|
||||
$post_date_gmt = '0000-00-00 00:00:00';
|
||||
}
|
||||
|
||||
if ( $update ) {
|
||||
|
||||
Reference in New Issue
Block a user