From 23514efe8aac5e4ee4979dda3fec1a45846ca306 Mon Sep 17 00:00:00 2001 From: Andrew Ozz Date: Wed, 22 May 2013 21:43:45 +0000 Subject: [PATCH] Local autosaves: always set 'autosave = true' in the post data when triggering local autosave on form submit. Fixes cases where the form is submitted shortly after loading the Edit screen, local autosave hasn't run yet and there is no previous data to be merged. Fixes #23960. git-svn-id: https://develop.svn.wordpress.org/trunk@24328 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/js/autosave.js | 1 + 1 file changed, 1 insertion(+) diff --git a/wp-includes/js/autosave.js b/wp-includes/js/autosave.js index d9e73a1abd..7f932221dc 100644 --- a/wp-includes/js/autosave.js +++ b/wp-includes/js/autosave.js @@ -488,6 +488,7 @@ wp.autosave.local = { } else { post_data = this.getData() || {}; $.extend( post_data, data ); + post_data.autosave = true; } // If the content and title did not change since the last save, don't save again