jenkins-bot has submitted this change and it was merged.

Change subject: Fix error handling for edit workflow
......................................................................


Fix error handling for edit workflow

Using this in wrong context

Bug: T94106
Change-Id: I01873f279b3d06d2069d7445ccdd375b2299e2b7
---
M resources/ext.gather.collection.editor/CollectionEditOverlay.js
1 file changed, 2 insertions(+), 1 deletion(-)

Approvals:
  Jhernandez: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/resources/ext.gather.collection.editor/CollectionEditOverlay.js 
b/resources/ext.gather.collection.editor/CollectionEditOverlay.js
index 482f6da..7e18565 100644
--- a/resources/ext.gather.collection.editor/CollectionEditOverlay.js
+++ b/resources/ext.gather.collection.editor/CollectionEditOverlay.js
@@ -58,6 +58,7 @@
                 */
                onSaveClick: function () {
                        var title = this.$( '.title' ).val(),
+                               self = this,
                                description = this.$( '.description' ).val();
 
                        if ( this.isTitleValid( title ) && 
this.isDescriptionValid( description ) ) {
@@ -74,7 +75,7 @@
                                                window.location.reload();
                                        } );
                                } ).fail( function ( errMsg ) {
-                                       toast.show( 
this.options.editFailedError, 'toast error' );
+                                       toast.show( 
self.options.editFailedError, 'toast error' );
                                        // Make it possible to try again.
                                        this.$( '.mw-ui-input, .save' ).prop( 
'disabled', false );
                                        schema.log( {

-- 
To view, visit https://gerrit.wikimedia.org/r/201594
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I01873f279b3d06d2069d7445ccdd375b2299e2b7
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/Gather
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson <jrob...@wikimedia.org>
Gerrit-Reviewer: Jhernandez <jhernan...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to