@cfworker/json-schema
Advanced tools
Comparing version 1.12.7 to 1.12.8
@@ -113,3 +113,3 @@ const DATE = /^(\d\d\d\d)-(\d\d)-(\d\d)$/; | ||
try { | ||
new RegExp(str); | ||
new RegExp(str, 'u'); | ||
return true; | ||
@@ -116,0 +116,0 @@ } |
@@ -429,3 +429,3 @@ import { deepCompareStrict } from './deep-compare-strict.js'; | ||
for (const pattern in $patternProperties) { | ||
const regex = new RegExp(pattern); | ||
const regex = new RegExp(pattern, 'u'); | ||
const subSchema = $patternProperties[pattern]; | ||
@@ -783,3 +783,3 @@ for (const key in instance) { | ||
} | ||
if ($pattern !== undefined && !new RegExp($pattern).test(instance)) { | ||
if ($pattern !== undefined && !new RegExp($pattern, 'u').test(instance)) { | ||
errors.push({ | ||
@@ -786,0 +786,0 @@ instanceLocation, |
{ | ||
"name": "@cfworker/json-schema", | ||
"type": "module", | ||
"version": "1.12.7", | ||
"version": "1.12.8", | ||
"description": "A JSON schema validator that will run on Cloudflare workers. Supports drafts 4, 7, 2019-09, and 2020-12.", | ||
@@ -6,0 +6,0 @@ "keywords": [ |
@@ -167,3 +167,3 @@ // based on https://github.com/epoberezkin/ajv/blob/master/lib/compile/formats.js | ||
try { | ||
new RegExp(str); | ||
new RegExp(str, 'u'); | ||
return true; | ||
@@ -170,0 +170,0 @@ } catch (e) { |
@@ -676,3 +676,3 @@ import { deepCompareStrict } from './deep-compare-strict.js'; | ||
for (const pattern in $patternProperties) { | ||
const regex = new RegExp(pattern); | ||
const regex = new RegExp(pattern, 'u'); | ||
const subSchema = $patternProperties[pattern]; | ||
@@ -1146,3 +1146,3 @@ for (const key in instance) { | ||
} | ||
if ($pattern !== undefined && !new RegExp($pattern).test(instance)) { | ||
if ($pattern !== undefined && !new RegExp($pattern, 'u').test(instance)) { | ||
errors.push({ | ||
@@ -1149,0 +1149,0 @@ instanceLocation, |
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
112988