Added try/catch block to handle exceptions if widgets.

This commit is contained in:
Martin Edenhofer 2016-08-31 23:18:34 +02:00
parent 8fd97df19a
commit af1aa0874d

View file

@ -43,10 +43,13 @@ class App.Run extends App.Controller
sortedKeys = Object.keys(widgets).sort()
for key in sortedKeys
widget = widgets[key]
new widget(
el: el
key: key
)
try
new widget(
el: el
key: key
)
catch e
@log 'error', "widget #{key}:", e
App.Event.trigger(event + ':ready')
class App.Content extends App.ControllerWidgetPermanent