fix: Fixed an issue where deleting a file from the preview modal would not correctly navigate to next item or dismiss the modal

This commit is contained in:
Aman Harwara
2023-03-30 12:40:50 +05:30
parent 860746d4e2
commit 7773becdec
3 changed files with 39 additions and 4 deletions

View File

@@ -51,7 +51,7 @@ const FilePreviewModal = observer(({ application, viewControllerManager }: Props
event.preventDefault()
const currentFileIndex = otherFiles.findIndex((fileFromArray) => fileFromArray.uuid === currentFile.uuid)
const currentFileIndex = otherFiles.findIndex((file) => file.uuid === currentFile.uuid)
switch (event.key) {
case KeyboardKey.Left: {