Ignore:
Timestamp:
01/21/25 03:08:24 (3 days ago)
Author:
stefan toskovski <stefantoska84@…>
Branches:
main
Parents:
0c6b92a
Message:

F4 Finalna Verzija

File:
1 edited

Legend:

Unmodified
Added
Removed
  • imaps-frontend/node_modules/es-abstract/2022/DefineMethodProperty.js

    r0c6b92a r79a0317  
    55var DefinePropertyOrThrow = require('./DefinePropertyOrThrow');
    66var IsExtensible = require('./IsExtensible');
    7 var IsPropertyKey = require('./IsPropertyKey');
    8 var Type = require('./Type');
     7
     8var isObject = require('../helpers/isObject');
     9var isPropertyKey = require('../helpers/isPropertyKey');
    910
    1011// https://262.ecma-international.org/13.0/#sec-definemethodproperty
    1112
    1213module.exports = function DefineMethodProperty(homeObject, key, closure, enumerable) {
    13         if (Type(homeObject) !== 'Object') {
     14        if (!isObject(homeObject)) {
    1415                throw new $TypeError('Assertion failed: `homeObject` is not an Object');
    1516        }
    16         if (!IsPropertyKey(key)) {
     17        if (!isPropertyKey(key)) {
    1718                throw new $TypeError('Assertion failed: `key` is not a Property Key or a Private Name');
    1819        }
Note: See TracChangeset for help on using the changeset viewer.