Skip to content

Commit

Permalink
try catch
Browse files Browse the repository at this point in the history
  • Loading branch information
Bod9001 committed Nov 19, 2023
1 parent 86f974d commit 9f92179
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions UnitystationLauncher/Services/CodeScanService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,15 @@ public async Task<bool> OnScan(ZipArchive archive, string targetDirectory, strin
info.Invoke("Proceeding to scan folder");
if (ScanFolder(dllDirectory, goodFileCopy, info, errors) == false)
{
DeleteContentsOfDirectory(processingDirectory);
DeleteContentsOfDirectory(stagingDirectory);
try
{
DeleteContentsOfDirectory(processingDirectory);
DeleteContentsOfDirectory(stagingDirectory);
}
catch (Exception e)
{
Log.Error(e.ToString());
}
return false;
}

Expand Down

0 comments on commit 9f92179

Please sign in to comment.