We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2ea0b35 commit 8d907e2Copy full SHA for 8d907e2
FlashpointManager/src/Common.cs
@@ -443,14 +443,17 @@ public static void DeleteFileAndDirectories(string file)
443
{
444
File.Delete(file);
445
}
446
- catch (Exception e) when (!(e is DirectoryNotFoundException))
+ catch (Exception e)
447
448
- GenericError(
449
- "Failed to delete the following file:\n" + file + "\n\n" +
450
- "Make sure it is not open or being used by another program."
451
- );
+ if (!(e is DirectoryNotFoundException))
+ {
+ GenericError(
+ "Failed to delete the following file:\n" + file + "\n\n" +
452
+ "Make sure it is not open or being used by another program."
453
+ );
454
- return;
455
+ return;
456
+ }
457
458
459
string folder = Path.GetDirectoryName(file);
0 commit comments