mirror of
https://github.com/awesome-selfhosted/awesome-selfhosted.git
synced 2025-04-23 13:22:10 +02:00
Fix JSON output
This commit is contained in:
parent
4c67cc50ed
commit
2b2071208f
1 changed files with 3 additions and 3 deletions
4
test.js
4
test.js
|
@ -31,12 +31,12 @@ function entryErrorCheck (md) {
|
|||
}
|
||||
if (totalFail > 0) {
|
||||
console.log(totalFail + ' Failed, ' + totalPass + ' Passed, of ' + total)
|
||||
log += '"error": "true",\n"title": "Found ' + totalFail + ' syntax error(s).",\n'
|
||||
log += ' "error": true,\n "title": "Found ' + totalFail + ' entries with syntax error(s).",\n'
|
||||
fs.writeFileSync('syntaxcheck.json', log + issuelog + '"\n}')
|
||||
process.exit(1)
|
||||
} else {
|
||||
console.log(totalFail + ' Failed, ' + totalPass + ' Passed, of ' + total + '\n')
|
||||
log += '"error": false,\n"title": "No errors found!"\n}'
|
||||
log += ' "error": false\n}'
|
||||
fs.writeFileSync('syntaxcheck.json', log)
|
||||
process.exit(0)
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue