mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
react app
This commit is contained in:
16
react-app/node_modules/core-js/modules/$.array-species-create.js
generated
vendored
Normal file
16
react-app/node_modules/core-js/modules/$.array-species-create.js
generated
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
// 9.4.2.3 ArraySpeciesCreate(originalArray, length)
|
||||
var isObject = require('./$.is-object')
|
||||
, isArray = require('./$.is-array')
|
||||
, SPECIES = require('./$.wks')('species');
|
||||
module.exports = function(original, length){
|
||||
var C;
|
||||
if(isArray(original)){
|
||||
C = original.constructor;
|
||||
// cross-realm fallback
|
||||
if(typeof C == 'function' && (C === Array || isArray(C.prototype)))C = undefined;
|
||||
if(isObject(C)){
|
||||
C = C[SPECIES];
|
||||
if(C === null)C = undefined;
|
||||
}
|
||||
} return new (C === undefined ? Array : C)(length);
|
||||
};
|
Reference in New Issue
Block a user