root / HServer / 00.Server / 00.Program / node_modules / object-keys / isArguments.js
이력 | 보기 | 이력해설 | 다운로드 (437 Bytes)
1 |
var toString = Object.prototype.toString;
|
---|---|
2 |
|
3 |
module.exports = function isArguments(value) { |
4 |
var str = toString.call(value);
|
5 |
var isArguments = str === '[object Arguments]'; |
6 |
if (!isArguments) {
|
7 |
isArguments = str !== '[object Array]'
|
8 |
&& value !== null
|
9 |
&& typeof value === 'object' |
10 |
&& typeof value.length === 'number' |
11 |
&& value.length >= 0
|
12 |
&& toString.call(value.callee) === '[object Function]';
|
13 |
} |
14 |
return isArguments;
|
15 |
}; |
16 |
|