Fixed issue deleting reservations

This commit is contained in:
Matthew Garrett 2023-04-14 13:06:35 -07:00
Родитель d17640ee88
Коммит b8300b3516
2 изменённых файлов: 2 добавлений и 1 удалений

Просмотреть файл

@ -1349,7 +1349,7 @@ async def delete_block_reservations(
if not_owned:
raise HTTPException(status_code=403, detail="Users can only delete their own reservations.")
filtered_req = [r for r in target_block['resv'] if not r['settledOn'] if r['id'] in req]
filtered_req = [r['id'] for r in target_block['resv'] if not r['settledOn'] if r['id'] in req]
for id in filtered_req:
index = next((i for i, item in enumerate(target_block['resv']) if item['id'] == id), None)

Просмотреть файл

@ -716,6 +716,7 @@ export default function EditReservations(props) {
}
} finally {
setSending(false);
refresh();
}
})();
}