From 5535d37a3e04af4025d07b79fab181e9c40ded52 Mon Sep 17 00:00:00 2001 From: Corey Johnson Date: Mon, 5 Nov 2012 11:10:49 -0800 Subject: [PATCH] Better error reporting when a grammar fails to load --- src/app/text-mate-grammar.coffee | 1 + 1 file changed, 1 insertion(+) diff --git a/src/app/text-mate-grammar.coffee b/src/app/text-mate-grammar.coffee index 3c5279e75..1a460700c 100644 --- a/src/app/text-mate-grammar.coffee +++ b/src/app/text-mate-grammar.coffee @@ -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