Skip to content

Commit a99ddfd

Browse files
committed
Merge branch 'pr/400' into main
2 parents 9cfd324 + 5e56bcb commit a99ddfd

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

UOP1_Project/Assets/Scripts/SaveSystem/FileManager.cs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,12 @@ public static bool MoveFile(string fileName, string newFileName)
5151
{
5252
File.Delete(newFullPath);
5353
}
54+
55+
if (!File.Exists(fullPath))
56+
{
57+
return false;
58+
}
59+
5460
File.Move(fullPath, newFullPath);
5561
}
5662
catch (Exception e)

0 commit comments

Comments
 (0)