From 1644fc369bf0ed608d92a8426ad444adfc2092de Mon Sep 17 00:00:00 2001 From: in-void Date: Sat, 18 Mar 2023 15:31:00 +0100 Subject: [PATCH] mobile device "not blank" name validation during updates --- internal/api/mobile/app/command/update_mobile_device.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/api/mobile/app/command/update_mobile_device.go b/internal/api/mobile/app/command/update_mobile_device.go index 6479781..42d2776 100644 --- a/internal/api/mobile/app/command/update_mobile_device.go +++ b/internal/api/mobile/app/command/update_mobile_device.go @@ -7,7 +7,7 @@ import ( type UpdateMobileDevice struct { Id string `uri:"device_id" validate:"required,uuid4"` - Name string `json:"name" validate:"max=128"` + Name string `json:"name" validate:"not_blank,max=128"` Platform string `json:"platform" validate:"omitempty,oneof=ios android huawei"` FcmToken string `json:"fcm_token" validate:"max=256"` }