Fix mass inserting messages

This commit is contained in:
Tulir Asokan 2024-02-18 23:10:31 +02:00
parent d0e3d2966a
commit 9402d0d291

View file

@ -107,7 +107,7 @@ func (mq *MessageQuery) MassInsert(key PortalKey, msgs []Message) {
params[0] = key.ChannelID
params[1] = key.Receiver
for i, msg := range msgs {
baseIndex := 2 + i*7
baseIndex := 2 + i*8
params[baseIndex] = msg.DiscordID
params[baseIndex+1] = msg.AttachmentID
params[baseIndex+2] = msg.SenderID