aboutsummaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
authorMichał Gołębiowski-Owczarek <m.goleb@gmail.com>2019-05-13 22:25:11 +0200
committerMichał Gołębiowski-Owczarek <m.goleb@gmail.com>2019-09-26 01:59:57 +0200
commitd7e13f128a4965f5d2bf510dc2314faa266f9dd7 (patch)
tree1c74baf73ca4430bae04948662abb4d67fa5ae12 /build
parent36b59c9661b7c24bb0271f813d2a02cac44de81a (diff)
downloadjquery-d7e13f128a4965f5d2bf510dc2314faa266f9dd7.tar.gz
jquery-d7e13f128a4965f5d2bf510dc2314faa266f9dd7.zip
Build: ESLint: forbid unused function parameters
This commit requires all function parameters to be used, not just the last one. In cases where that's not possible as we need to match an external API, there's an escape hatch of prefixing an unused argument with `_`. This change makes it easier to catch unused AMD dependencies and unused parameters in internal functions the API of which we may change at will, among other things. Unused AMD dependencies have been removed as part of this commit. Closes gh-4381 (cherry-picked from 438b1a3e8a52d3e4efd8aba45498477038849c97)
Diffstat (limited to 'build')
-rw-r--r--build/tasks/build.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/build/tasks/build.js b/build/tasks/build.js
index b59ef816e..73dfd581d 100644
--- a/build/tasks/build.js
+++ b/build/tasks/build.js
@@ -372,7 +372,7 @@ module.exports = function( grunt ) {
// Ask for permission the first time
if ( insight.optOut === undefined ) {
- insight.askPermission( null, function( error, result ) {
+ insight.askPermission( null, function( _error, result ) {
exec( result );
} );
} else {