commit 30a539d46f8b002a31111054f0dc4808b48e7813 parent 56ec2a86516f4f9c2a34e3f26701ec21950179e4 Author: n0tr1v <n0tr1v@protonmail.com> Date: Sat, 10 Jun 2023 03:41:32 -0700 rename var Diffstat:
| M | pkg/web/handlers/interceptors/slashInterceptor.go | | | 4 | ++-- |
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pkg/web/handlers/interceptors/slashInterceptor.go b/pkg/web/handlers/interceptors/slashInterceptor.go @@ -1322,12 +1322,12 @@ func handleDeleteMsgCmd(c *command.Command) (handled bool) { return command.ErrRedirect } if c.Message == "/d" { - msg1, err := c.DB.GetUserLastChatMessageInRoom(c.AuthUser.ID, c.Room.ID) + lastMsg, err := c.DB.GetUserLastChatMessageInRoom(c.AuthUser.ID, c.Room.ID) if err != nil { c.Err = errors.New("unable to find last message") return true } - msgs := []database.ChatMessage{msg1} + msgs := []database.ChatMessage{lastMsg} c.Err = delMsgFn(msgs) return true