lib/timber/util/http_event.rb in timber-2.0.6 vs lib/timber/util/http_event.rb in timber-2.0.7
- old
+ new
@@ -29,11 +29,15 @@
k = k.to_s.downcase
case k
when AUTHORIZATION_HEADER
h[k] = SANITIZED_VALUE
else
- h[k] = v
+ if Config.instance.header_filters && Config.instance.header_filters.include?(k)
+ h[k] = SANITIZED_VALUE
+ else
+ h[k] = v
+ end
end
end
else
headers
end
@@ -46,10 +50,10 @@
def normalize_query_string(query_string)
if !query_string.nil?
query_string = query_string.to_s
end
- query_string[0..(QUERY_STRING_LIMIT - 1)]
+ query_string && query_string[0..(QUERY_STRING_LIMIT - 1)]
end
end
end
end
\ No newline at end of file