From d5a4b93449889dbfec19b7335cf74be3e53db267 Mon Sep 17 00:00:00 2001 From: Douglas Christopher Wilson Date: Wed, 3 Dec 2014 21:08:54 -0500 Subject: [PATCH] Add link to root directory closes #23 --- HISTORY.md | 5 +++++ public/directory.html | 2 +- test/test.js | 5 +++-- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/HISTORY.md b/HISTORY.md index c524488..d89b7b8 100644 --- a/HISTORY.md +++ b/HISTORY.md @@ -1,3 +1,8 @@ +unreleased +========== + + * Add link to root directory + 1.5.3 / 2014-12-10 ================== diff --git a/public/directory.html b/public/directory.html index 8ed8b4a..cda1601 100644 --- a/public/directory.html +++ b/public/directory.html @@ -75,7 +75,7 @@
-

{linked-path}

+

~{linked-path}

{files}
diff --git a/test/test.js b/test/test.js index d775bc8..a4046db 100644 --- a/test/test.js +++ b/test/test.js @@ -145,8 +145,9 @@ describe('serveIndex(root)', function () { .expect(200) .expect('Content-Type', 'text/html; charset=utf-8') .end(function (err, res) { - if (err) throw err; - var urls = res.text.split(/')[1]; + var urls = body.split(/