You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 rivejä
564 B

4 vuotta sitten
  1. var coreJsData = require('./_coreJsData');
  2. /** Used to detect methods masquerading as native. */
  3. var maskSrcKey = (function() {
  4. var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');
  5. return uid ? ('Symbol(src)_1.' + uid) : '';
  6. }());
  7. /**
  8. * Checks if `func` has its source masked.
  9. *
  10. * @private
  11. * @param {Function} func The function to check.
  12. * @returns {boolean} Returns `true` if `func` is masked, else `false`.
  13. */
  14. function isMasked(func) {
  15. return !!maskSrcKey && (maskSrcKey in func);
  16. }
  17. module.exports = isMasked;