2022-11-29 05:09:21PM

This commit is contained in:
Alexander Wang 2022-11-29 17:09:21 -08:00
parent 7cbcd88f9c
commit de56cda278
No known key found for this signature in database
GPG key ID: D89FA31966BDBECE

View file

@ -238,7 +238,7 @@ func compile(ctx context.Context, ms *xmain.State, isWatching bool, plugin d2plu
// Missing/broken images are fine during watch mode, as the user is likely building up a diagram. // Missing/broken images are fine during watch mode, as the user is likely building up a diagram.
// Otherwise, the assumption is that this diagram is building for production, and broken images are not okay. // Otherwise, the assumption is that this diagram is building for production, and broken images are not okay.
if !isWatching && ms.Log.Nerrors() > 0 { if !isWatching && ms.Log.Nerrors() > 0 {
xmain.ExitErrorf(1, "errors logged while rendering, partial output written to %v", outputPath) return nil, xmain.ExitErrorf(1, "errors logged while rendering, partial output written to %v", outputPath)
} }
return svg, nil return svg, nil