diff options
Diffstat (limited to 'lib/book.js')
-rw-r--r-- | lib/book.js | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/book.js b/lib/book.js index bdd4dfc..42e2c23 100644 --- a/lib/book.js +++ b/lib/book.js @@ -675,8 +675,8 @@ Book.prototype.resolve = function(p) { return path.resolve(this.root, p); }; -// Normalize a link to .html and convert README -> index -Book.prototype.contentLink = function(link) { +// Normalize a path to .html and convert README -> index +Book.prototype.contentPath = function(link) { if ( path.basename(link, path.extname(link)) == "README" || link == this.readmeFile @@ -688,6 +688,11 @@ Book.prototype.contentLink = function(link) { return link; } +// Normalize a link to .html and convert README -> index +Book.prototype.contentLink = function(link) { + return links.normalize(this.contentPath(link)); +} + // Index a page into the search index Book.prototype.indexPage = function(page) { var nav = this.navigation[page.path]; |