Improved error handling.

This commit is contained in:
Martin Edenhofer 2016-03-24 16:22:23 +01:00
parent 698f69d1b0
commit ed89aa5da8

View file

@ -251,15 +251,15 @@ class _taskManagerSingleton extends App.Controller
return false if !controller return false if !controller
# set controller state to active # set controller state to active
if controller.active if controller.active && _.isFunction(controller.active)
controller.active(true) controller.active(true)
# execute controllers show # execute controllers show
if controller.show if controller.show && _.isFunction(controller.show)
controller.show(params_app) controller.show(params_app)
# update title # update title
if controller.meta if controller.meta && _.isFunction(controller.meta)
meta = controller.meta() meta = controller.meta()
@title meta.title @title meta.title
@ -273,11 +273,11 @@ class _taskManagerSingleton extends App.Controller
return false if !controller return false if !controller
# set controller state to active # set controller state to active
if controller.active if controller.active && _.isFunction(controller.active)
controller.active(false) controller.active(false)
# execute controllers hide # execute controllers hide
if controller.hide if controller.hide && _.isFunction(controller.hide)
controller.hide() controller.hide()
true true