Skip to content

Commit bd015c5

Browse files
authored
chore: update pdfpig nuget package version (#9803)
1 parent c3e8352 commit bd015c5

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

Directory.Packages.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<PackageVersion Include="Newtonsoft.Json" Version="13.0.3" />
2424
<PackageVersion Include="OneOf" Version="3.0.263" />
2525
<PackageVersion Include="OneOf.SourceGenerator" Version="3.0.263" />
26-
<PackageVersion Include="PdfPig" Version="0.1.9-alpha-20240312-845e3" />
26+
<PackageVersion Include="PdfPig" Version="0.1.9-alpha-20240318-69e2b" />
2727
<PackageVersion Include="PlantUml.Net" Version="1.4.80" />
2828
<PackageVersion Include="Spectre.Console" Version="0.48.0" />
2929
<PackageVersion Include="Spectre.Console.Cli" Version="0.48.0" />

src/Docfx.App/PdfBuilder.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ await Parallel.ForEachAsync(pages, async (item, _) =>
291291
if (outline.pdfTocPage)
292292
{
293293
var href = $"/_pdftoc{outlineUrl.AbsolutePath}";
294-
yield return (new(outlineUrl, href), new() { href = href, pdfPrintBackground = outline.pdfPrintBackground });
294+
yield return (new(outlineUrl, href), new() { href = href, pdfPrintBackground = outline.pdfPrintBackground });
295295
}
296296

297297
if (!string.IsNullOrEmpty(outline.href))
@@ -325,6 +325,9 @@ async Task MergePdf()
325325
// Refresh TOC page numbers
326326
updatePageNumbers(pageNumbers);
327327
bytes = await printPdf(outline, url);
328+
329+
if (bytes == null)
330+
continue;
328331
}
329332

330333
using var document = PdfDocument.Open(bytes);

0 commit comments

Comments
 (0)