mirror of
https://github.com/GitbookIO/gitbook.git
synced 2026-09-16 07:35:16 +00:00
Check that readme file is not ignored when parsing
This commit is contained in:
@@ -228,6 +228,7 @@ Book.prototype.parseReadme = function() {
|
||||
return that.findFile(that.config.getStructure("readme"))
|
||||
.then(function(readme) {
|
||||
if (!readme) throw "No README file";
|
||||
if (!_.contains(that.files, readme.path)) throw "README file is ignored";
|
||||
|
||||
that.readmeFile = readme.path;
|
||||
return that.template.renderFile(readme.path)
|
||||
|
||||
Reference in New Issue
Block a user