Folowup I341c3f7c: Fire wikipage.content with the correct content
authorMoriel Schottlender <moriel@gmail.com>
Thu, 23 Feb 2017 21:54:41 +0000 (13:54 -0800)
committerMoriel Schottlender <moriel@gmail.com>
Thu, 23 Feb 2017 21:54:41 +0000 (13:54 -0800)
The content we are getting from the Ajax request can be either a
jQuery or string, which makes the handler of the event break.

Instead, pass in this.$element which already wrapped the response.

Change-Id: I1c1231b1476fb2cbef10231fdd853401ebf02ed3

resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.ChangesListWrapperWidget.js

index a2a6b16..84248e1 100644 (file)
                        this.applyHighlight();
 
                        // Make sure enhanced RC re-initializes correctly
-                       mw.hook( 'wikipage.content' ).fire( this.$changesListContent );
+                       mw.hook( 'wikipage.content' ).fire( this.$element );
                }
                this.popPending();
        };