diff --git a/internal/domain/subreddit.go b/internal/domain/subreddit.go index 5727264..9c06797 100644 --- a/internal/domain/subreddit.go +++ b/internal/domain/subreddit.go @@ -23,7 +23,7 @@ func (sr *Subreddit) NormalizedName() string { func (sr *Subreddit) Validate() error { return validation.ValidateStruct(sr, - validation.Field(&sr.Name, validation.Required, validation.Length(3, 32), validation.Match(regexp.MustCompile("^(?!u_)[a-zA-Z0-9]\\w{1,19}$"))), + validation.Field(&sr.Name, validation.Required, validation.Length(3, 32), validation.Match(regexp.MustCompile(`^(?!u_)[a-zA-Z0-9]\w{1,19}$`))), validation.Field(&sr.SubredditID, validation.Required, validation.Length(4, 9)), ) }