lib/adhearsion/component_manager.rb in adhearsion-1.0.3 vs lib/adhearsion/component_manager.rb in adhearsion-1.1.0

- old
+ new

@@ -132,9 +132,16 @@ method_definition_blocks.each do |method_definition_block| @scopes[scope].module_eval(&method_definition_block) end end container + rescue StandardError => e + # Non-fatal errors + Events.trigger(['exception'], e) + rescue Exception => e + # Fatal errors. Log them and keep passing them upward + Events.trigger(['exception'], e) + raise e end class ComponentDefinitionContainer < Module class << self