lib/webgen/contentprocessor/haml.rb in webgen-0.5.11 vs lib/webgen/contentprocessor/haml.rb in webgen-0.5.12

- old
+ new

@@ -14,19 +14,20 @@ locals = {:context => context} context.content = ::Haml::Engine.new(context.content, :filename => context.ref_node.alcn). render(Object.new, locals) context rescue LoadError - raise Webgen::LoadError.new('haml', self.class.name, context.dest_node.alcn, 'haml') + raise Webgen::LoadError.new('haml', self.class.name, context.dest_node, 'haml') rescue ::Haml::Error => e line = if e.line e.line + 1 else Webgen::Common.error_line(e) end - raise Webgen::RenderError.new(e, self.class.name, context.dest_node.alcn, context.ref_node.alcn, line) + raise Webgen::RenderError.new(e, self.class.name, context.dest_node, context.ref_node, line) rescue Exception => e - raise Webgen::RenderError.new(e, self.class.name, context.dest_node.alcn, context.ref_node.alcn, Webgen::Common.error_line(e)) + raise Webgen::RenderError.new(e, self.class.name, context.dest_node, + Webgen::Common.error_file(e), Webgen::Common.error_line(e)) end end end