We are talking to the developer that this type of token can not be found

This commit is contained in:
Костя Третяк 2018-01-07 15:33:55 +02:00
parent ba2645774d
commit c66cd5efc0
No known key found for this signature in database
GPG Key ID: 9E8D9A17FDB9DC4C

View File

@ -1082,6 +1082,14 @@ Parser.prototype.tok = function() {
case 'text': {
return this.renderer.paragraph(this.parseText());
}
default: {
var errMsg = 'Token with "' + this.token.type + '" type was not found.';
if (this.options.silent) {
console.log(errMsg);
} else {
throw new Error(errMsg);
}
}
}
};