diff --git a/lib/capybara-page-object/page.rb b/lib/capybara-page-object/page.rb
index <HASH>..<HASH> 100644
--- a/lib/capybara-page-object/page.rb
+++ b/lib/capybara-page-object/page.rb
@@ -14,10 +14,7 @@ module CapybaraPageObject
       if attr.kind_of?(String)
         target += attr
       elsif attr.kind_of?(Hash)
-        pairs = []
-        attr.each do |k, v|
-          pairs << "#{k}=#{v}"
-        end
+        pairs = attr.map { |k, v| "#{k}=#{v}" }
         target += '?' + pairs.join('&') if pairs.any?
       elsif attr != nil
         raise ArgumentError
Cleaner way to construct the query string