Skip to content

Commit

Permalink
Merge pull request #19261 from Automattic/update/post-editor-autosave
Browse files Browse the repository at this point in the history
Post Editor: adds autosave parameter to outbound queries
  • Loading branch information
roccotripaldi authored Nov 16, 2017
2 parents 0e0926f + a3a0b8d commit 258a95d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion client/lib/posts/actions.js
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ PostActions = {
}
);
} else {
PostActions.saveEdited( null, null, callback, { recordSaveEvent: false } );
PostActions.saveEdited( null, null, callback, { recordSaveEvent: false, autosave: true } );
}
},

Expand Down Expand Up @@ -347,6 +347,9 @@ PostActions = {
context: 'edit',
apiVersion: '1.2',
};
if ( options && options.autosave ) {
query.autosave = options.autosave;
}

if ( ! options || options.recordSaveEvent !== false ) {
recordSaveEvent( context ); // do this before changing status from 'future'
Expand Down

0 comments on commit 258a95d

Please sign in to comment.