From e4fd41f8fa4190fbbb6cb98cf7ace64f6e00685d Mon Sep 17 00:00:00 2001 From: Oleg Gaidarenko Date: Fri, 15 Jul 2016 21:42:25 +0400 Subject: Build: Update eslint config and fix associated errors --- src/core/access.js | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'src/core') diff --git a/src/core/access.js b/src/core/access.js index 735c75711..86cdbc7e6 100644 --- a/src/core/access.js +++ b/src/core/access.js @@ -53,13 +53,16 @@ var access = function( elems, fn, key, value, chainable, emptyGet, raw ) { } } - return chainable ? - elems : + if ( chainable ) { + return elems; + } + + // Gets + if ( bulk ) { + return fn.call( elems ); + } - // Gets - bulk ? - fn.call( elems ) : - len ? fn( elems[ 0 ], key ) : emptyGet; + return len ? fn( elems[ 0 ], key ) : emptyGet; }; return access; -- cgit v1.2.3