Fix old items not being removed when queue type is changed

This commit is contained in:
regalijan 2023-10-19 16:51:07 -04:00
parent 8b1e44fa91
commit 267cc02c96
Signed by: regalijan
GPG Key ID: 5D4196DA269EF520

View File

@ -186,7 +186,10 @@ export default function () {
}
}
if (!entryData.length) return;
if (!entryData.length) {
setEntries([]);
return;
}
for (const entry of entryData) {
let cardType = queue_type;
@ -301,7 +304,7 @@ export default function () {
onClose={itemModals.infraction.onClose}
/>
<Flex>
<VStack w={isDesktop ? "container.md" : "container.lg"}>
<VStack maxW="container.lg">
<Box display={isDesktop ? "none" : undefined} mb="16px">
{ItemDisplay}
</Box>