diff options
author | Samy Pesse <samypesse@gmail.com> | 2016-04-26 11:00:36 +0200 |
---|---|---|
committer | Samy Pesse <samypesse@gmail.com> | 2016-04-26 11:00:36 +0200 |
commit | 8a3f80ba82bd706083015f228c551d64768a287e (patch) | |
tree | 1afa30295ff795ec209e91501f6d4146dd1dd4d4 /lib/models/file.js | |
parent | 374ebd6f7a77bfbde00f5d1e730403afd86e018f (diff) | |
download | gitbook-8a3f80ba82bd706083015f228c551d64768a287e.zip gitbook-8a3f80ba82bd706083015f228c551d64768a287e.tar.gz gitbook-8a3f80ba82bd706083015f228c551d64768a287e.tar.bz2 |
Add test for parsing glossary
Diffstat (limited to 'lib/models/file.js')
-rw-r--r-- | lib/models/file.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/models/file.js b/lib/models/file.js index b6b06ee..ff7b899 100644 --- a/lib/models/file.js +++ b/lib/models/file.js @@ -20,6 +20,15 @@ File.prototype.getMTime = function() { }; /** + Does the file exists / is set + + @return {Boolean} +*/ +File.prototype.exists = function() { + return Boolean(this.getPath()); +}; + +/** Return type of file ('markdown' or 'asciidoc') @return {String} |