Legend:
- Unmodified
- Added
- Removed
-
imaps-frontend/node_modules/es-abstract/2016/OrdinaryGetOwnProperty.js
r0c6b92a r79a0317 4 4 var $TypeError = require('es-errors/type'); 5 5 6 var callBound = require('call-b ind/callBound');6 var callBound = require('call-bound'); 7 7 8 8 var $isEnumerable = callBound('Object.prototype.propertyIsEnumerable'); … … 11 11 12 12 var IsArray = require('./IsArray'); 13 var IsPropertyKey = require('./IsPropertyKey');13 var isPropertyKey = require('../helpers/isPropertyKey'); 14 14 var IsRegExp = require('./IsRegExp'); 15 15 var ToPropertyDescriptor = require('./ToPropertyDescriptor'); 16 var Type = require('./Type'); 16 17 var isObject = require('../helpers/isObject'); 17 18 18 19 // https://262.ecma-international.org/6.0/#sec-ordinarygetownproperty 19 20 20 21 module.exports = function OrdinaryGetOwnProperty(O, P) { 21 if ( Type(O) !== 'Object') {22 if (!isObject(O)) { 22 23 throw new $TypeError('Assertion failed: O must be an Object'); 23 24 } 24 if (! IsPropertyKey(P)) {25 if (!isPropertyKey(P)) { 25 26 throw new $TypeError('Assertion failed: P must be a Property Key'); 26 27 }
Note:
See TracChangeset
for help on using the changeset viewer.