mirror of
https://github.com/liamcottle/reticulum-meshchat.git
synced 2026-04-28 09:43:13 +00:00
fix for accidentally removing outbound chat items that don't have an id yet
This commit is contained in:
parent
8c011dd72f
commit
827b453055
1 changed files with 2 additions and 2 deletions
|
|
@ -2293,9 +2293,9 @@
|
|||
// delete lxmf message from server
|
||||
await window.axios.delete(`/api/v1/lxmf-messages/${chatItem.lxmf_message.id}`);
|
||||
|
||||
// remove lxmf message from chat items
|
||||
// remove lxmf message from chat items using hash, as other pending items might not have an id yet
|
||||
this.chatItems = this.chatItems.filter((item) => {
|
||||
return item.lxmf_message?.id !== chatItem.lxmf_message.id;
|
||||
return item.lxmf_message?.hash !== chatItem.lxmf_message.hash;
|
||||
});
|
||||
|
||||
} catch(e) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue