From 5415670a8cc136cc611010d732471ea93286384a Mon Sep 17 00:00:00 2001 From: Jamie Nelson Date: Sun, 11 Oct 2026 07:55:25 +1100 Subject: [PATCH] fix: complete SVG writes before reporting success --- src/svg-editor.mts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/svg-editor.mts b/src/svg-editor.mts index bb75df2f..7574b4e0 100644 --- a/src/svg-editor.mts +++ b/src/svg-editor.mts @@ -107,9 +107,8 @@ export default class SVGEditor { writeSVGFile(svgPath: string, svgContent: string): void { fs.mkdirSync(path.dirname(svgPath), { recursive: true }); this.log.debug(`Writing SVG file to ${svgPath}`); - fs.writeFile(svgPath, svgContent, 'utf8', () => { - return this.log.debug(`SVG image generated: ${svgPath}`); - }); + fs.writeFileSync(svgPath, svgContent, 'utf8'); + this.log.debug(`SVG image generated: ${svgPath}`); } /**