Skip to content

Commit

Permalink
fix: restrict length of tag
Browse files Browse the repository at this point in the history
  • Loading branch information
ppolariss committed Jul 11, 2024
1 parent a45c760 commit 1ba6d58
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion apis/hole/schemas.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ func (q *ListOldModel) SetDefaults() {
}

type TagCreateModelSlice struct {
Tags []tag.CreateModel `json:"tags" validate:"omitempty,min=1,max=20,dive"` // All users
Tags []tag.CreateModel `json:"tags" validate:"omitempty,min=1,max=10,dive"` // All users
}

func (tagCreateModelSlice TagCreateModelSlice) ToName() []string {
Expand Down
2 changes: 1 addition & 1 deletion apis/tag/schemas.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package tag

type CreateModel struct {
Name string `json:"name,omitempty" validate:"max=10"` // Admin only
Name string `json:"name,omitempty" validate:"max=20"` // Admin only
}

type ModifyModel struct {
Expand Down

0 comments on commit 1ba6d58

Please sign in to comment.