diff --git a/activesupport/lib/active_support/core_ext/hash/conversions.rb b/activesupport/lib/active_support/core_ext/hash/conversions.rb index 74e23bd884..a77fb55747 100644 --- a/activesupport/lib/active_support/core_ext/hash/conversions.rb +++ b/activesupport/lib/active_support/core_ext/hash/conversions.rb @@ -9,7 +9,7 @@ class Object end def to_query(key) #:nodoc: - "#{key}=#{CGI.escape(to_param)}" + "#{key}=#{CGI.escape(to_param || "")}" end end