diff --git a/app/models/concerns/crosscitable.rb b/app/models/concerns/crosscitable.rb index 450531d65..b7d0474c8 100644 --- a/app/models/concerns/crosscitable.rb +++ b/app/models/concerns/crosscitable.rb @@ -48,11 +48,11 @@ def parse_xml(input, options={}) meta = from.present? ? send("read_" + from, { string: input, doi: options[:doi], sandbox: sandbox }).compact : {} meta.merge("string" => input, "from" => from) - rescue NoMethodError, ArgumentError => exception - Raven.capture_exception(exception) + rescue NoMethodError, ArgumentError => e + Raven.capture_exception(e) - Rails.logger.error "Error " + exception.message + " for doi " + @doi + "." - Rails.logger.error exception + Rails.logger.error "Error " + e.message + " for doi " + @doi + "." if e.message.present? + Rails.logger.error exception.inspect {} end