Fix variable scope in ArticleTargetSaver

Also fix docs

Change-Id: Ida47968c995166b1dca36fc9fe28fac374010564
This commit is contained in:
Ed Sanders 2020-01-24 15:32:46 -08:00
parent 2abe5931e9
commit 62145b11e6

View file

@ -116,13 +116,14 @@
* Serializes the document to HTML, deflates it, then passes to #postHtml.
*
* @param {HTMLDocument} doc Document to save
* @param {Object} extraData Extra data to send to the API
* @param {Object} options Options
* @param {Object} [extraData] Extra data to send to the API
* @param {Object} [options] Options
* @return {jQuery.Promise} Promise which resolves if the post was successful
*/
saveDoc: function ( doc, extraData, options ) {
var saver = this;
return this.deflateDoc( doc ).then( function ( html ) {
return this.postHtml(
return saver.postHtml(
html,
null,
extraData,