diff options
author | Samy Pessé <samypesse@gmail.com> | 2016-05-12 15:12:08 +0200 |
---|---|---|
committer | Samy Pessé <samypesse@gmail.com> | 2016-05-12 15:12:08 +0200 |
commit | 2e74fafa36c35c11148c09d4745402f23c53c1f8 (patch) | |
tree | f620a2c1dc056af4ff3e61b60c3ec53ed99571c7 /lib/output/helper/resolveFileToURL.js | |
parent | 28ac9ab88a009711837c379c3b18ab7f901299c6 (diff) | |
download | gitbook-2e74fafa36c35c11148c09d4745402f23c53c1f8.zip gitbook-2e74fafa36c35c11148c09d4745402f23c53c1f8.tar.gz gitbook-2e74fafa36c35c11148c09d4745402f23c53c1f8.tar.bz2 |
Add template method "getPageByPath"
Diffstat (limited to 'lib/output/helper/resolveFileToURL.js')
-rw-r--r-- | lib/output/helper/resolveFileToURL.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/output/helper/resolveFileToURL.js b/lib/output/helper/resolveFileToURL.js index 3dba8f7..026b0e5 100644 --- a/lib/output/helper/resolveFileToURL.js +++ b/lib/output/helper/resolveFileToURL.js @@ -13,8 +13,7 @@ function resolveFileToURL(output, filePath) { // Convert /test.png -> test.png filePath = LocationUtils.toAbsolute(filePath, '', ''); - var pages = output.getPages(); - var page = pages.get(filePath); + var page = output.getPage(filePath); // if file is a page, return correct .html url if (page) { |