mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-05 01:17:50 +00:00
lint files (#4416)
* lint files * added back arrow-paren and removed duplicate
This commit is contained in:
committed by
John-David Dalton
parent
5b4dc54465
commit
15e1557b2a
@@ -1,6 +1,7 @@
|
||||
import isArrayLike from '../isArrayLike.js'
|
||||
import isIndex from './isIndex.js'
|
||||
import isObject from '../isObject.js'
|
||||
import eq from '../eq.js'
|
||||
|
||||
/**
|
||||
* Checks if the given arguments are from an iteratee call.
|
||||
@@ -15,16 +16,16 @@ import isObject from '../isObject.js'
|
||||
|
||||
function isIterateeCall(value, index, object) {
|
||||
if (!isObject(object)) {
|
||||
return false;
|
||||
return false
|
||||
}
|
||||
const type = typeof index;
|
||||
const type = typeof index
|
||||
if (type == 'number'
|
||||
? (isArrayLike(object) && isIndex(index, object.length))
|
||||
: (type == 'string' && index in object)
|
||||
) {
|
||||
return eq(object[index], value);
|
||||
return eq(object[index], value)
|
||||
}
|
||||
return false;
|
||||
return false
|
||||
}
|
||||
|
||||
export default isIterateeCall
|
||||
|
||||
Reference in New Issue
Block a user