Fix index out of range when deleting the final image
This commit is contained in:
parent
ba7e2a5328
commit
53809e3b3f
|
@ -106,8 +106,8 @@ class ImageView(tk.Frame):
|
|||
caption_path = img.caption_path()
|
||||
if caption_path.exists():
|
||||
caption_path.rename(trash_path / caption_path.name)
|
||||
|
||||
del self.images[self.index]
|
||||
self.set_index(self.index)
|
||||
self.update_ui()
|
||||
|
||||
def update_ui(self):
|
||||
|
|
Loading…
Reference in New Issue