summaryrefslogtreecommitdiffstats
path: root/lib/utils/location.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/utils/location.js')
-rw-r--r--lib/utils/location.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/utils/location.js b/lib/utils/location.js
index ba0c57d..ba43644 100644
--- a/lib/utils/location.js
+++ b/lib/utils/location.js
@@ -27,7 +27,7 @@ function isAnchor(href) {
// Normalize a path to be a link
function normalize(s) {
- return s.replace(/\\/g, '/');
+ return path.normalize(s).replace(/\\/g, '/');
}
// Convert relative to absolute path
@@ -36,7 +36,7 @@ function normalize(s) {
function toAbsolute(_href, dir, outdir) {
if (isExternal(_href)) return _href;
outdir = outdir == undefined? dir : outdir;
-
+
_href = normalize(_href);
dir = normalize(dir);
outdir = normalize(outdir);