Skip to content

Commit

Permalink
See #1432. Improves JS-Beautify beautifier so it will throw error whe…
Browse files Browse the repository at this point in the history
…n missing language

See #1458, #1471, #1483, #136, #1452
  • Loading branch information
Glavin001 committed Jan 25, 2017
1 parent d091570 commit 46d4975
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/beautifiers/js-beautify.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ module.exports = class JSBeautify extends Beautifier
beautifyCSS = require("js-beautify").css
text = beautifyCSS(text, options)
resolve text
else
reject(new Error("Unknown language for JS Beautify: "+language))
catch err
@error("JS Beautify error: #{err}")
reject(err)
Expand Down

0 comments on commit 46d4975

Please sign in to comment.