summaryrefslogtreecommitdiff
path: root/internal/validate/formvalidation.go
diff options
context:
space:
mode:
authorLibravatar Julian-Samuel Gebühr <julian-samuel@gebuehr.net>2023-06-02 17:42:14 +0200
committerLibravatar GitHub <noreply@github.com>2023-06-02 17:42:14 +0200
commit1f39275c0f4ff3356a480ef7f0339d54547968e5 (patch)
tree8ba20351dfc6b0f1a8caec4673ed658d7147b807 /internal/validate/formvalidation.go
parent[bugfix] Overwrite API client closed errors with `499 - Client Closed Request... (diff)
downloadgotosocial-1f39275c0f4ff3356a480ef7f0339d54547968e5.tar.xz
[bugfix] Allow lowercase emoji shortcode in frontend (#1851)
* Replace pinafore with semaphore * Typo * Allow lowercase emoji shortcode in frontend * Fix failing test (corrected expected outcome)
Diffstat (limited to 'internal/validate/formvalidation.go')
-rw-r--r--internal/validate/formvalidation.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/validate/formvalidation.go b/internal/validate/formvalidation.go
index c122bf2bc..c4028ec66 100644
--- a/internal/validate/formvalidation.go
+++ b/internal/validate/formvalidation.go
@@ -179,10 +179,10 @@ func CustomCSS(customCSS string) error {
// EmojiShortcode just runs the given shortcode through the regular expression
// for emoji shortcodes, to figure out whether it's a valid shortcode, ie., 2-30 characters,
-// lowercase a-z, numbers, and underscores.
+// a-zA-Z, numbers, and underscores.
func EmojiShortcode(shortcode string) error {
if !regexes.EmojiShortcode.MatchString(shortcode) {
- return fmt.Errorf("shortcode %s did not pass validation, must be between 2 and 30 characters, lowercase letters, numbers, and underscores only", shortcode)
+ return fmt.Errorf("shortcode %s did not pass validation, must be between 2 and 30 characters, letters, numbers, and underscores only", shortcode)
}
return nil
}