Fix delete action for hidden photos

This commit is contained in:
Sam Becker 2024-07-24 23:09:43 -05:00
parent 17c4b54478
commit 8d525820db

View File

@ -239,7 +239,7 @@ export const toggleFavoritePhotoAction = async (
export const deletePhotosAction = async (photoIds: string[]) =>
runAuthenticatedAdminServerAction(async () => {
for (const photoId of photoIds) {
const photo = await getPhoto(photoId);
const photo = await getPhoto(photoId, true);
if (photo) {
await deletePhoto(photoId).then(() => deleteFile(photo.url));
}