wallet-core/node_modules/core-js/modules/es6.regexp.split.js

12 lines
424 B
JavaScript
Raw Normal View History

2016-10-10 03:43:44 +02:00
// @@split logic
require('./$.fix-re-wks')('split', 2, function(defined, SPLIT, $split){
2016-10-10 03:43:44 +02:00
// 21.1.3.17 String.prototype.split(separator, limit)
return function split(separator, limit){
'use strict';
2016-10-10 03:43:44 +02:00
var O = defined(this)
, fn = separator == undefined ? undefined : separator[SPLIT];
return fn !== undefined
? fn.call(separator, O, limit)
: $split.call(String(O), separator, limit);
};
2016-10-10 03:43:44 +02:00
});