Skip to content

Commit

Permalink
Ensure archive generator stream is closed before continuing
Browse files Browse the repository at this point in the history
  • Loading branch information
bastianeicher committed Feb 3, 2020
1 parent 05241ff commit 5d8a2c4
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Publish/ImplementationUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,11 @@ private static void GenerateMissingArchive(Implementation implementation, ITaskH

implementation.UpdateDigest(directoryPath, handler, executor);

using var generator = ArchiveGenerator.Create(
using (var generator = ArchiveGenerator.Create(
directoryPath,
archiveHref.LocalPath,
archive.MimeType ?? Archive.GuessMimeType(archiveHref.LocalPath));
handler.RunTask(generator);
archive.MimeType ?? Archive.GuessMimeType(archiveHref.LocalPath)))
handler.RunTask(generator);

executor.Execute(SetValueCommand.For(() => archive.Size, newValue: new FileInfo(archiveHref.LocalPath).Length));
executor.Execute(SetValueCommand.For<string?>(() => implementation.LocalPath, newValue: null));
Expand Down

0 comments on commit 5d8a2c4

Please sign in to comment.