summaryrefslogtreecommitdiffstats
path: root/lib/template/loader.js
diff options
context:
space:
mode:
authorSamy Pesse <samypesse@gmail.com>2016-02-11 18:18:33 +0100
committerSamy Pesse <samypesse@gmail.com>2016-02-11 18:18:33 +0100
commite7eed2abbe91fa44bd071819123bd9ea04d1702a (patch)
treedb6290eec86c94cb31ab8d2eeb26fa7145c6c09e /lib/template/loader.js
parent98a13cf487e3b2823cfde38ab1d1b8f97f614517 (diff)
downloadgitbook-e7eed2abbe91fa44bd071819123bd9ea04d1702a.zip
gitbook-e7eed2abbe91fa44bd071819123bd9ea04d1702a.tar.gz
gitbook-e7eed2abbe91fa44bd071819123bd9ea04d1702a.tar.bz2
Complete conrefs in parsing
Diffstat (limited to 'lib/template/loader.js')
-rw-r--r--lib/template/loader.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/template/loader.js b/lib/template/loader.js
index 23ffb77..5d30fb2 100644
--- a/lib/template/loader.js
+++ b/lib/template/loader.js
@@ -16,16 +16,16 @@ var Loader = nunjucks.Loader.extend({
this.git = new Git(this.fs.tmpdir());
},
- getSource: function(soureURL, callback) {
+ getSource: function(sourceURL, callback) {
var that = this;
- this.git.resolveFile(soureURL)
+ this.git.resolve(sourceURL)
.then(function(filepath) {
// Is local file
if (!filepath) {
- filepath = that.book.resolve(soureURL);
+ filepath = that.book.resolve(sourceURL);
} else {
- that.book.log.debug.ln('resolve from git', soureURL, 'to', filepath);
+ that.book.log.debug.ln('resolve from git', sourceURL, 'to', filepath);
}
// Read file from absolute path