@babel/runtime
Advanced tools
Comparing version 7.20.0 to 7.20.1
@@ -29,3 +29,8 @@ import _typeof from "./typeof.js"; | ||
var result = _super.exec.call(this, str); | ||
return result && (result.groups = buildGroups(result, this)), result; | ||
if (result) { | ||
result.groups = buildGroups(result, this); | ||
var indices = result.indices; | ||
indices && (indices.groups = buildGroups(indices, this)); | ||
} | ||
return result; | ||
}, BabelRegExp.prototype[Symbol.replace] = function (str, substitution) { | ||
@@ -35,3 +40,4 @@ if ("string" == typeof substitution) { | ||
return _super[Symbol.replace].call(this, str, substitution.replace(/\$<([^>]+)>/g, function (_, name) { | ||
return "$" + groups[name]; | ||
var group = groups[name]; | ||
return "$" + (Array.isArray(group) ? group.join("$") : group); | ||
})); | ||
@@ -38,0 +44,0 @@ } |
@@ -29,3 +29,8 @@ var _typeof = require("./typeof.js")["default"]; | ||
var result = _super.exec.call(this, str); | ||
return result && (result.groups = buildGroups(result, this)), result; | ||
if (result) { | ||
result.groups = buildGroups(result, this); | ||
var indices = result.indices; | ||
indices && (indices.groups = buildGroups(indices, this)); | ||
} | ||
return result; | ||
}, BabelRegExp.prototype[Symbol.replace] = function (str, substitution) { | ||
@@ -35,3 +40,4 @@ if ("string" == typeof substitution) { | ||
return _super[Symbol.replace].call(this, str, substitution.replace(/\$<([^>]+)>/g, function (_, name) { | ||
return "$" + groups[name]; | ||
var group = groups[name]; | ||
return "$" + (Array.isArray(group) ? group.join("$") : group); | ||
})); | ||
@@ -38,0 +44,0 @@ } |
{ | ||
"name": "@babel/runtime", | ||
"version": "7.20.0", | ||
"version": "7.20.1", | ||
"description": "babel's modular runtime helpers", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
218418
4239