Update checked-in dependencies
This commit is contained in:
parent
1afca056e3
commit
6989ba7bd2
3942 changed files with 55190 additions and 132206 deletions
12
node_modules/es-abstract/2016/IsDataDescriptor.js
generated
vendored
12
node_modules/es-abstract/2016/IsDataDescriptor.js
generated
vendored
|
|
@ -1,10 +1,10 @@
|
|||
'use strict';
|
||||
|
||||
var has = require('has');
|
||||
var $TypeError = require('es-errors/type');
|
||||
|
||||
var Type = require('./Type');
|
||||
var hasOwn = require('hasown');
|
||||
|
||||
var assertRecord = require('../helpers/assertRecord');
|
||||
var isPropertyDescriptor = require('../helpers/records/property-descriptor');
|
||||
|
||||
// https://262.ecma-international.org/5.1/#sec-8.10.2
|
||||
|
||||
|
|
@ -13,9 +13,11 @@ module.exports = function IsDataDescriptor(Desc) {
|
|||
return false;
|
||||
}
|
||||
|
||||
assertRecord(Type, 'Property Descriptor', 'Desc', Desc);
|
||||
if (!isPropertyDescriptor(Desc)) {
|
||||
throw new $TypeError('Assertion failed: `Desc` must be a Property Descriptor');
|
||||
}
|
||||
|
||||
if (!has(Desc, '[[Value]]') && !has(Desc, '[[Writable]]')) {
|
||||
if (!hasOwn(Desc, '[[Value]]') && !hasOwn(Desc, '[[Writable]]')) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue