lib/appsignal/zipped_payload.rb in appsignal-0.11.10.beta.1 vs lib/appsignal/zipped_payload.rb in appsignal-0.11.10.beta.2

- old
+ new

@@ -16,22 +16,22 @@ end def self.jsonify(value) case value when String - begin - value.encode('utf-8') - rescue Encoding::UndefinedConversionError - '[invalid-utf8]' - end + value.encode( + 'utf-8', + :invalid => :replace, + :undef => :replace + ) when Numeric, NilClass, TrueClass, FalseClass value when Hash Hash[value.map { |k, v| [jsonify(k), jsonify(v)] }] when Array value.map { |v| jsonify(v) } else - jsonify value.to_s + jsonify(value.to_s) end end end end