Update markdown-it dependency to 4.0.1, fix breaking changes.

This commit is contained in:
David Anson 2015-03-18 23:14:44 -07:00
parent e305d22cce
commit c764d2798f
4 changed files with 25 additions and 24 deletions

View file

@ -64,12 +64,12 @@ function lintFile(file, config, callback) {
var lines = contents.split(shared.newLineRe);
// Annotate tokens with line/lineNumber
tokens.forEach(function forToken(token) {
if (token.lines) {
token.line = lines[token.lines[0]];
token.lineNumber = token.lines[0] + 1;
if (token.map) {
token.line = lines[token.map[0]];
token.lineNumber = token.map[0] + 1;
// Trim bottom of token to exclude whitespace lines
while (!(lines[token.lines[1] - 1].trim())) {
token.lines[1]--;
while (!(lines[token.map[1] - 1].trim())) {
token.map[1]--;
}
}
});