commit 364c878ac7a47620db69977bae593c5dcdde2b5c
parent 0bc6517884e30242ef1950c1ce4da29257665e49
Author: n0tr1v <n0tr1v@protonmail.com>
Date: Sun, 26 Mar 2023 21:15:50 -0700
messages should start/end with spaces
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pkg/web/handlers/api/v1/topBarHandler.go b/pkg/web/handlers/api/v1/topBarHandler.go
@@ -264,7 +264,7 @@ func ChatTopBarHandler(c echo.Context) error {
return c.Render(http.StatusOK, "chat-top-bar", data)
}
- origMessage := c.Request().PostFormValue("message")
+ origMessage := strings.TrimSpace(c.Request().PostFormValue("message"))
cmd := NewCommand(c, origMessage, room, roomKey)
cmd.redirectQP = redirectQP