Skip to content

Commit

Permalink
Fix create-property.js
Browse files Browse the repository at this point in the history
  • Loading branch information
stonechoe committed Jan 25, 2024
1 parent 7ffd975 commit 17d7dc2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions packages/core-js/internals/create-property.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,5 @@ var createPropertyDescriptor = require('../internals/create-property-descriptor'

module.exports = function (object, key, value) {
var propertyKey = toPropertyKey(key);
if (propertyKey in object) definePropertyModule.f(object, propertyKey, createPropertyDescriptor(0, value));
else object[propertyKey] = value;
definePropertyModule.f(object, propertyKey, createPropertyDescriptor(0, value));
};

0 comments on commit 17d7dc2

Please # to comment.