mirror of
https://github.com/atom/atom.git
synced 2026-01-24 22:38:20 -05:00
Better error reporting when a grammar fails to load
This commit is contained in:
committed by
Corey Johnson & Nathan Sobo
parent
f6b5b4d3bd
commit
5535d37a3e
@@ -9,6 +9,7 @@ class TextMateGrammar
|
||||
plist.parseString fs.read(path), (e, data) ->
|
||||
throw new Error(e) if e
|
||||
grammar = new TextMateGrammar(data[0])
|
||||
throw new Error("Failed to load grammar at path `#{path}`") unless grammar
|
||||
grammar
|
||||
|
||||
name: null
|
||||
|
||||
Reference in New Issue
Block a user