eslint: Turn on reportUnusedDisableDirectives
authorEd Sanders <esanders@wikimedia.org>
Fri, 14 Dec 2018 14:22:26 +0000 (14:22 +0000)
committerEd Sanders <esanders@wikimedia.org>
Fri, 14 Dec 2018 14:22:26 +0000 (14:22 +0000)
Change-Id: I3fb88324ba5a46e44041c13eb6447c8e33f4e79b

Gruntfile.js
resources/src/mediawiki.rcfilters/dm/mw.rcfilters.dm.FilterGroup.js
resources/src/startup/mediawiki.js

index 6be908e..707a1fb 100644 (file)
@@ -21,6 +21,9 @@ module.exports = function ( grunt ) {
 
        grunt.initConfig( {
                eslint: {
+                       options: {
+                               reportUnusedDisableDirectives: true
+                       },
                        all: [
                                '**/*.js',
                                '!docs/**',
index 9264a39..df2079e 100644 (file)
 
                                subsetNames = [];
 
-                               filter.subset.forEach( function ( subsetFilterName ) { // eslint-disable-line no-loop-func
+                               filter.subset.forEach( function ( subsetFilterName ) {
                                        // Subsets (unlike conflicts) are always inside the same group
                                        // We can re-map the names of the filters we are getting from
                                        // the subsets with the group prefix
index fee69c0..03f02b4 100644 (file)
@@ -99,7 +99,6 @@
         * @param {string} [data.module] Name of module which caused the error
         */
        function logError( topic, data ) {
-               /* eslint-disable no-console */
                var msg,
                        e = data.exception,
                        source = data.source,
                                console.warn( e );
                        }
                }
-               /* eslint-enable no-console */
        }
 
        /**