lib/knj/errors.rb in knjrbfw-0.0.32 vs lib/knj/errors.rb in knjrbfw-0.0.33
- old
+ new
@@ -32,11 +32,14 @@
end
str = ""
if args[:html]
- str << "<b>#{err.class.name}</b>: #{err.message}<br />\n<br />\n"
- str << err.backtrace.join("<br />\n")
+ str << "<b>#{Knj::Web.html(err.class.name)}</b>: #{Knj::Web.html(err.message)}<br />\n<br />\n"
+
+ err.backtrace.each do |bt|
+ str << "#{Knj::Web.html(bt)}<br />\n"
+ end
else
str << "#{err.class.name}: #{err.message}\n\n"
str << err.backtrace.join("\n")
end
\ No newline at end of file