From d9db762b8628b785f948f9a380e9687398c4741e Mon Sep 17 00:00:00 2001 From: Artem Date: Mon, 4 Nov 2024 16:55:07 +0300 Subject: [PATCH] Fix: auth endpoints validation --- cmd/api/handler/rollup_auth.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/api/handler/rollup_auth.go b/cmd/api/handler/rollup_auth.go index df7748d7..9f3281b6 100644 --- a/cmd/api/handler/rollup_auth.go +++ b/cmd/api/handler/rollup_auth.go @@ -49,7 +49,7 @@ type createRollupRequest struct { Explorer string `json:"explorer" validate:"omitempty,url"` Stack string `json:"stack" validate:"omitempty"` Links []string `json:"links" validate:"omitempty,dive,url"` - Category string `json:"category" validate:"omitempty,oneof=nft gaming finance uncategorized"` + Category string `json:"category" validate:"omitempty,category"` Type string `json:"type" validate:"omitempty,oneof=settled sovereign"` Compression string `json:"compression" validate:"omitempty"` VM string `json:"vm" validate:"omitempty"` @@ -162,7 +162,7 @@ type updateRollupRequest struct { Bridge string `json:"bridge" validate:"omitempty,eth_addr"` Explorer string `json:"explorer" validate:"omitempty,url"` Stack string `json:"stack" validate:"omitempty"` - Category string `json:"category" validate:"omitempty,oneof=nft gaming finance uncategorized"` + Category string `json:"category" validate:"omitempty,category"` Type string `json:"type" validate:"omitempty,oneof=settled sovereign"` Compression string `json:"compression" validate:"omitempty"` Provider string `json:"provider" validate:"omitempty"`