From d10e01d0d55fd6d3481a129e96592db2ca3d88ac Mon Sep 17 00:00:00 2001 From: kfule Date: Tue, 22 Oct 2024 00:52:30 +0900 Subject: [PATCH] remove polyfill for Object.assign() The polyfill doesn't support multiple source objects, and almost all browsers now natively support Object.assign(). --- util/assign.js | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/util/assign.js b/util/assign.js index 1695f4b3a..38a421f3f 100644 --- a/util/assign.js +++ b/util/assign.js @@ -1,10 +1,4 @@ // This exists so I'm only saving it once. "use strict" -var hasOwn = require("./hasOwn") - -module.exports = Object.assign || function(target, source) { - for (var key in source) { - if (hasOwn.call(source, key)) target[key] = source[key] - } -} +module.exports = Object.assign