Skip to content

Commit e6ca10a

Browse files
committed
chore: remove tag id and value max len
1 parent eb07f49 commit e6ca10a

2 files changed

Lines changed: 2 additions & 4 deletions

File tree

src/schemas/base-schema.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ export const createdAtSchema = Schema.number().min(0).multiple(1).custom(seconds
1818

1919
// [<string>, <string> 0..*]
2020
export const tagSchema = Schema.array()
21-
.ordered(Schema.string().max(255).required().label('identifier'))
22-
.items(Schema.string().allow('').max(1024).label('value'))
21+
.ordered(Schema.string().required().label('identifier'))
22+
.items(Schema.string().allow('').label('value'))
2323
.label('tag')

test/unit/schemas/event-schema.spec.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,12 +119,10 @@ describe('NIP-01', () => {
119119
],
120120
identifier: [
121121
{ message: 'must be a string', transform: assocPath(['tags', 0, 0], null) },
122-
{ message: 'length must be less than or equal to 255 characters long', transform: assocPath(['tags', 0, 0], ' '.repeat(256)) },
123122
{ message: 'is not allowed to be empty', transform: assocPath(['tags', 0, 0], '') },
124123
],
125124
value: [
126125
{ message: 'must be a string', transform: assocPath(['tags', 0, 1], null) },
127-
{ message: 'length must be less than or equal to 1024 characters long', transform: assocPath(['tags', 0, 1], ' '.repeat(1024 + 1)) },
128126
],
129127
}
130128

0 commit comments

Comments
 (0)