Fixed killing of the dom

This commit is contained in:
Nicolai Ort 2023-04-12 20:54:00 +02:00
parent f6c1fea17c
commit 2f62c7ae89
Signed by: niggl
GPG Key ID: 13AFA55AF62F269F

View File

@ -206,9 +206,21 @@
on:click={async () => {
const prom = [];
for (const card of selectedCards) {
prom.push(deleteCard(card.id));
prom.push(
await RunnerCardService.runnerCardControllerRemove(
card.id,
true
)
);
}
await Promise.all(prom);
for (const card of selectedCards) {
current_cards = current_cards.filter((r) => r.id !== card.id);
}
options.update((options) => ({
...options,
data: current_cards,
}));
}}
>
{$_("delete-cards")}