summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorSamy Pessé <samypesse@gmail.com>2016-02-18 12:13:24 +0100
committerSamy Pessé <samypesse@gmail.com>2016-02-18 12:13:24 +0100
commit576d773fecf5ec6a7ebf5b089ff7a03b102468eb (patch)
treec6967bf852bc8405e410c7f738f0c00c6c728531 /lib
parent58a930e456860a025cb8565effe73fb3ae437882 (diff)
downloadgitbook-576d773fecf5ec6a7ebf5b089ff7a03b102468eb.zip
gitbook-576d773fecf5ec6a7ebf5b089ff7a03b102468eb.tar.gz
gitbook-576d773fecf5ec6a7ebf5b089ff7a03b102468eb.tar.bz2
Correctly map filenames for website output
Diffstat (limited to 'lib')
-rw-r--r--lib/output/base.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/output/base.js b/lib/output/base.js
index e674f46..09f57bc 100644
--- a/lib/output/base.js
+++ b/lib/output/base.js
@@ -184,9 +184,10 @@ Output.prototype.resolveForPage = function(page, href) {
// Filename for output
// READMEs are replaced by index.html
+// /test/README.md -> /test/index.html
Output.prototype.outputPath = function(filename, ext) {
ext = ext || this.defaultExtension;
- var output;
+ var output = filename;
if (
path.basename(filename, path.extname(filename)) == 'README' ||