lib/zold/json_page.rb in zold-0.16.30 vs lib/zold/json_page.rb in zold-0.17.0
- old
+ new
@@ -38,9 +38,9 @@
def to_hash
raise 'JSON is empty, can\'t parse' + (@uri.empty? ? '' : " at #{@uri}") if @text.empty?
JSON.parse(@text)
rescue JSON::ParserError => e
- raise "Failed to parse JSON #{@uri.empty? ? '' : "at #{@uri}"} (#{e.message}): #{@text}"
+ raise "Failed to parse JSON #{@uri.empty? ? '' : "at #{@uri}"} (#{e.message}): #{@text.inspect}"
end
end
end