Catrope has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/383730 )
Change subject: Make sure ReplyWidget isn't destroyed while it's pending ...................................................................... Make sure ReplyWidget isn't destroyed while it's pending ReplyWidget disables the editor while it's pending, which means that we'll try to destroy the VE surface while it's disabled, which breaks. Bug: T166634 Change-Id: I506d9115e2cbfa8a73307ec9f9c62be0360d05a5 --- M modules/flow/ui/widgets/mw.flow.ui.ReplyWidget.js 1 file changed, 4 insertions(+), 3 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Flow refs/changes/30/383730/1 diff --git a/modules/flow/ui/widgets/mw.flow.ui.ReplyWidget.js b/modules/flow/ui/widgets/mw.flow.ui.ReplyWidget.js index c3a5ebc..dfe1f94 100644 --- a/modules/flow/ui/widgets/mw.flow.ui.ReplyWidget.js +++ b/modules/flow/ui/widgets/mw.flow.ui.ReplyWidget.js @@ -144,6 +144,10 @@ widget.canNotEdit.toggle( false ); widget.expanded = false; } + + // Make sure the widget is no longer pending when we emit the event, + // otherwise destroying it breaks (T166634) + widget.editor.popPending(); widget.emit( 'saveContent', workflow, content, format ); } ) .then( null, function ( errorCode, errorObj ) { @@ -152,9 +156,6 @@ widget.error.setLabel( new OO.ui.HtmlSnippet( errorObj.error && errorObj.error.info || errorObj.exception ) ); widget.error.toggle( true ); } - - } ) - .always( function () { widget.editor.popPending(); } ); }; -- To view, visit https://gerrit.wikimedia.org/r/383730 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I506d9115e2cbfa8a73307ec9f9c62be0360d05a5 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Flow Gerrit-Branch: master Gerrit-Owner: Catrope <r...@wikimedia.org> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits