From acf16883ec185a28818acc3504f08746f19449fd Mon Sep 17 00:00:00 2001 From: thorn0 Date: Tue, 2 Feb 2016 03:26:31 +0200 Subject: [PATCH] refactor(injector): remove unneeded JSHint directives --- src/auto/injector.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/auto/injector.js b/src/auto/injector.js index 25781aa91b02..7bcb42532df6 100644 --- a/src/auto/injector.js +++ b/src/auto/injector.js @@ -861,9 +861,7 @@ function createInjector(modulesToLoad, strictDi) { return fn.apply(self, args); } else { args.unshift(null); - /*jshint -W058 */ // Applying a constructor without immediate parentheses is the point here. - return new (Function.prototype.bind.apply(fn, args)); - /*jshint +W058 */ + return new (Function.prototype.bind.apply(fn, args))(); } } @@ -875,9 +873,7 @@ function createInjector(modulesToLoad, strictDi) { var args = injectionArgs(Type, locals, serviceName); // Empty object at position 0 is ignored for invocation with `new`, but required. args.unshift(null); - /*jshint -W058 */ // Applying a constructor without immediate parentheses is the point here. - return new (Function.prototype.bind.apply(ctor, args)); - /*jshint +W058 */ + return new (Function.prototype.bind.apply(ctor, args))(); }