1
0
Fork 0
mirror of https://github.com/teamcapybara/capybara.git synced 2022-11-09 12:08:07 -05:00

Remove unused xpath_options parameter. Closes #588

Ruby 1.9 would silently drop the options as an extra parameter in
block.call, but Ruby 1.8 would convert the block parameters to an array,
causing breakage. The following code demonstrates the difference -- Ruby
1.9 prints 42, whereas Ruby 1.8 prints [42, {}]:

    def a(&block)
      block.call(42, {})
    end
    a do |x|
      p x
    end
This commit is contained in:
Jo Liss 2012-01-03 19:33:39 +01:00
parent bbc2b84b24
commit 9e1600f022

View file

@ -46,8 +46,8 @@ module Capybara
@failure_message
end
def call(locator, xpath_options={})
@xpath.call(locator, xpath_options)
def call(locator)
@xpath.call(locator)
end
def match?(locator)