From 4baaa41ac9a5ee16422bb922550bef7991026c9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Samy=20Pess=C3=A9?= Date: Wed, 28 Jan 2015 18:34:09 +0100 Subject: [PATCH] Fix for good path resolution of svg image --- lib/utils/page.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/utils/page.js b/lib/utils/page.js index 647f5579e..0166288c3 100644 --- a/lib/utils/page.js +++ b/lib/utils/page.js @@ -97,7 +97,7 @@ function normalizeHtml(src, options) { // Replace extension if (isExternal) { - dest = path.basename(src, ext)+".png"; + dest = path.basename(srcAbs, ext)+".png"; } else { dest = path.join(path.dirname(srcAbs), path.basename(srcAbs, ext)+".png"); dest = dest[0] == "/"? dest.slice(1) : dest; @@ -123,7 +123,7 @@ function normalizeHtml(src, options) { dest: path.join("./", dest) }); - src = dest; + src = path.join("/", dest); } // Reset as relative to output