@sanity/schema 6.5.0-next.30 → 6.5.0-next.35
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/lib/_internal.js +1 -2
- package/lib/_internal.js.map +1 -1
- package/package.json +6 -6
package/lib/_internal.js
CHANGED
|
@@ -2553,8 +2553,7 @@ function stringToRegExp(str) {
|
|
|
2553
2553
|
return match ? new RegExp(match[1], match[2]) : new RegExp(str);
|
|
2554
2554
|
}
|
|
2555
2555
|
function isRegexPattern(val) {
|
|
2556
|
-
return typeof val == "object" && val !== null && "type" in val &&
|
|
2557
|
-
val.type === "regex" && "pattern" in val && typeof val.pattern == "string";
|
|
2556
|
+
return typeof val == "object" && val !== null && "type" in val && val.type === "regex" && "pattern" in val && typeof val.pattern == "string";
|
|
2558
2557
|
}
|
|
2559
2558
|
function regexPatternToRegExp(val) {
|
|
2560
2559
|
const match = val.pattern.match(/^\(\?([a-z]+)\)(.*)$/);
|