lib/appium_lib/android/element/button.rb in appium_lib-9.15.1 vs lib/appium_lib/android/element/button.rb in appium_lib-9.15.2

- old
+ new

@@ -24,10 +24,11 @@ # If value is omitted, all buttons are returned. # @param value [String] the value to search for # @return [Array<Button>] def buttons(value = false) return find_elements :uiautomator, _button_visible_selectors unless value + find_elements :uiautomator, _button_contains_string(value) end # Find the first button. # @return [Button] @@ -67,9 +68,10 @@ private # @private def raise_no_such_element_if_empty(elements) raise _no_such_element if elements.empty? + elements.first end # @private def _button_visible_selectors(opts = {})