filter out deleted messages in payload 🗑️

This commit is contained in:
Danny Liu 2024-02-20 13:53:47 -08:00
parent 60c99a44f8
commit cd3cecd2f0

View file

@ -348,7 +348,7 @@
content: $settings.system content: $settings.system
} }
: undefined, : undefined,
...messages ...messages.filter((message) => !message.deleted)
] ]
.filter((message) => message) .filter((message) => message)
.map((message, idx, arr) => ({ .map((message, idx, arr) => ({
@ -555,7 +555,7 @@
content: $settings.system content: $settings.system
} }
: undefined, : undefined,
...messages ...messages.filter((message) => !message.deleted)
] ]
.filter((message) => message) .filter((message) => message)
.map((message, idx, arr) => ({ .map((message, idx, arr) => ({