From 52041becf717e5b0f2cb4b6bb43db5f4e0fe6b7f Mon Sep 17 00:00:00 2001 From: Ben Potter Date: Sat, 30 Jul 2022 22:34:59 +0000 Subject: [PATCH] Revert "chore: relax template name validation" This reverts commit 7806f3bebea02b216a09e3c8fc0053f71ea5774d. --- codersdk/organizations.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codersdk/organizations.go b/codersdk/organizations.go index 6f3b766998..2d3c3b3a92 100644 --- a/codersdk/organizations.go +++ b/codersdk/organizations.go @@ -48,7 +48,7 @@ type CreateTemplateVersionRequest struct { // CreateTemplateRequest provides options when creating a template. type CreateTemplateRequest struct { // Name is the name of the template. - Name string `json:"name" validate:"lt=32,required"` + Name string `json:"name" validate:"username,required"` // Description is a description of what the template contains. It must be // less than 128 bytes. Description string `json:"description,omitempty" validate:"lt=128"`