aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--packages/json-schemas/schemas/basic_type_schemas.ts2
-rw-r--r--packages/json-schemas/test/schema_test.ts2
2 files changed, 2 insertions, 2 deletions
diff --git a/packages/json-schemas/schemas/basic_type_schemas.ts b/packages/json-schemas/schemas/basic_type_schemas.ts
index 2cf32b384..7565df9e0 100644
--- a/packages/json-schemas/schemas/basic_type_schemas.ts
+++ b/packages/json-schemas/schemas/basic_type_schemas.ts
@@ -7,7 +7,7 @@ export const addressSchema = {
export const hexSchema = {
id: '/Hex',
type: 'string',
- pattern: '^0x([0-9a-f][0-9a-f])*$',
+ pattern: '^0x([0-9a-f][0-9a-f])+$',
};
export const numberSchema = {
diff --git a/packages/json-schemas/test/schema_test.ts b/packages/json-schemas/test/schema_test.ts
index a7d510122..379f92442 100644
--- a/packages/json-schemas/test/schema_test.ts
+++ b/packages/json-schemas/test/schema_test.ts
@@ -90,7 +90,7 @@ describe('Schema', () => {
validateAgainstSchema(testCases, hexSchema);
});
it('should fail for invalid hex string', () => {
- const testCases = ['0x', '0', '0x00', '0xzzzzzzB11a196601eD2ce54B665CaFEca0347D42'];
+ const testCases = ['0x', '0', '0xzzzzzzB11a196601eD2ce54B665CaFEca0347D42'];
const shouldFail = true;
validateAgainstSchema(testCases, hexSchema, shouldFail);
});