PR comments

This commit is contained in:
Bernard Xie 2022-11-21 11:09:41 -08:00
parent 794df257a7
commit cb6d3c298d
No known key found for this signature in database
GPG key ID: 3C3E0036CE0F892C

View file

@ -202,13 +202,14 @@ func compile(ctx context.Context, ms *xmain.State, plugin d2plugin.Plugin, theme
if err != nil { if err != nil {
return nil, err return nil, err
} }
out, err := plugin.PostProcess(ctx, svg) svg, err = plugin.PostProcess(ctx, svg)
if err != nil { if err != nil {
return nil, err return nil, err
} }
out := svg
if filepath.Ext(outputPath) == ".png" { if filepath.Ext(outputPath) == ".png" {
out, err = png.ConvertSVG(ms, page, out) out, err = png.ConvertSVG(ms, page, svg)
if err != nil { if err != nil {
return nil, err return nil, err
} }