Skip to content

Commit

Permalink
fixed installer
Browse files Browse the repository at this point in the history
  • Loading branch information
phasephasephase committed Mar 16, 2024
1 parent 8929e24 commit 300032e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion JiayiInstaller/Util.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public static async Task ExtractAndDelete(string zipPath, string extractPath)
Directory.CreateDirectory(extractPath);

// extract everything BUT wwwroot/css/theme.css
using var archive = ZipFile.OpenRead(zipPath);
var archive = ZipFile.OpenRead(zipPath);
foreach (var entry in archive.Entries)
{
if (entry.FullName == "wwwroot/css/theme.css") continue;
Expand All @@ -27,8 +27,12 @@ public static async Task ExtractAndDelete(string zipPath, string extractPath)
await using var stream = entry.Open();
await using var fileStream = File.Create(path);
await stream.CopyToAsync(fileStream);

fileStream.Close();
stream.Close();
}

archive.Dispose();
File.Delete(zipPath);
}

Expand Down

0 comments on commit 300032e

Please sign in to comment.