lib/instana/util.rb in instana-1.197.0.pre1 vs lib/instana/util.rb in instana-1.197.0.pre2
- old
+ new
@@ -154,11 +154,13 @@
#
# @param header_id [String] the header value to be converted
#
# @return [String]
#
- def header_to_id(header_id)
- header_id.is_a?(String) && header_id.match(/\A[a-z\d]{16,32}\z/i) ? header_id : ''
+ def header_to_id(given)
+ return '' unless given.is_a?(String)
+ return '' unless given.match(/\A[a-z\d]{16,32}\z/i)
+ given
end
end
end
end