From 7225dfe8c33780952f3abff4cc030d37cc3b9676 Mon Sep 17 00:00:00 2001 From: Alex Clapperton Date: Mon, 27 Apr 2020 12:07:24 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fix=20breaking=20change=20from?= =?UTF-8?q?=20mkdirp=20module?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index ec78776..6246e7e 100644 --- a/index.js +++ b/index.js @@ -278,8 +278,9 @@ var spriteSVG = function(options) { // Render our template and then save the file function renderTemplate(file) { var compiled = mustache.render(file.contents, file.data); - mkdirp(path.dirname(file.dest), function(){ - fs.writeFile(file.dest, compiled); + + mkdirp(path.dirname(file.dest)).then(() => { + fs.writeFile(file.dest, compiled); }); }