core-js 3.30.0 → 3.30.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/internals/shared.js
CHANGED
|
@@ -4,9 +4,9 @@ var store = require('../internals/shared-store');
|
|
|
4
4
|
(module.exports = function (key, value) {
|
|
5
5
|
return store[key] || (store[key] = value !== undefined ? value : {});
|
|
6
6
|
})('versions', []).push({
|
|
7
|
-
version: '3.30.
|
|
7
|
+
version: '3.30.1',
|
|
8
8
|
mode: IS_PURE ? 'pure' : 'global',
|
|
9
9
|
copyright: '© 2014-2023 Denis Pushkarev (zloirock.ru)',
|
|
10
|
-
license: 'https://github.com/zloirock/core-js/blob/v3.30.
|
|
10
|
+
license: 'https://github.com/zloirock/core-js/blob/v3.30.1/LICENSE',
|
|
11
11
|
source: 'https://github.com/zloirock/core-js'
|
|
12
12
|
});
|
|
@@ -1,13 +1,20 @@
|
|
|
1
1
|
var $ = require('../internals/export');
|
|
2
2
|
var getBuiltIn = require('../internals/get-built-in');
|
|
3
|
+
var fails = require('../internals/fails');
|
|
3
4
|
var validateArgumentsLength = require('../internals/validate-arguments-length');
|
|
4
5
|
var toString = require('../internals/to-string');
|
|
6
|
+
var USE_NATIVE_URL = require('../internals/url-constructor-detection');
|
|
5
7
|
|
|
6
8
|
var URL = getBuiltIn('URL');
|
|
7
9
|
|
|
10
|
+
// https://github.com/nodejs/node/issues/47505
|
|
11
|
+
var THROWS_WITHOUT_ARGUMENTS = USE_NATIVE_URL && fails(function () {
|
|
12
|
+
URL.canParse();
|
|
13
|
+
});
|
|
14
|
+
|
|
8
15
|
// `URL.canParse` method
|
|
9
16
|
// https://url.spec.whatwg.org/#dom-url-canparse
|
|
10
|
-
$({ target: 'URL', stat: true }, {
|
|
17
|
+
$({ target: 'URL', stat: true, forced: !THROWS_WITHOUT_ARGUMENTS }, {
|
|
11
18
|
canParse: function canParse(url) {
|
|
12
19
|
var length = validateArgumentsLength(arguments.length, 1);
|
|
13
20
|
var urlString = toString(url);
|