diff options
author | grant-kun <[email protected]> | 2022-09-26 07:14:29 -0500 |
---|---|---|
committer | grant-kun <[email protected]> | 2022-09-26 07:14:29 -0500 |
commit | 86feb9e6403cfa6198ffb6895877c1c00d2a738a (patch) | |
tree | cf29210132c5ffb2be80afe04eb0fa231dac3382 /node_modules/has-symbols/index.js | |
parent | 47e3ae49258f9ddfb91b570745fedeaef4f0fc8f (diff) |
update (not working)
Diffstat (limited to 'node_modules/has-symbols/index.js')
-rw-r--r-- | node_modules/has-symbols/index.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/node_modules/has-symbols/index.js b/node_modules/has-symbols/index.js new file mode 100644 index 0000000..17044fa --- /dev/null +++ b/node_modules/has-symbols/index.js @@ -0,0 +1,13 @@ +'use strict'; + +var origSymbol = typeof Symbol !== 'undefined' && Symbol; +var hasSymbolSham = require('./shams'); + +module.exports = function hasNativeSymbols() { + if (typeof origSymbol !== 'function') { return false; } + if (typeof Symbol !== 'function') { return false; } + if (typeof origSymbol('foo') !== 'symbol') { return false; } + if (typeof Symbol('bar') !== 'symbol') { return false; } + + return hasSymbolSham(); +}; |