Skip to content

Commit

Permalink
Fix crash on move codex if cover art already exists
Browse files Browse the repository at this point in the history
  • Loading branch information
DSPaul committed Nov 29, 2024
1 parent 663c2ad commit 43ff7f1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ViewModels/CodexViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -287,9 +287,9 @@ public static void MoveToCollection(CodexCollection targetCollection, List<Codex
tempCodex.SetImagePaths(targetCollection);

if (Path.Exists(toMove.CoverArt))
File.Copy(toMove.CoverArt, tempCodex.CoverArt);
File.Copy(toMove.CoverArt, tempCodex.CoverArt, true);
if (Path.Exists(toMove.CoverArt))
File.Copy(toMove.Thumbnail, tempCodex.Thumbnail);
File.Copy(toMove.Thumbnail, tempCodex.Thumbnail, true);

//Delete codex in original collection
MainViewModel.CollectionVM.CurrentCollection.DeleteCodex(toMove);
Expand Down

0 comments on commit 43ff7f1

Please sign in to comment.