lib/appium_lib/android/common/helper.rb in appium_lib-15.0.0 vs lib/appium_lib/android/common/helper.rb in appium_lib-15.2.0

- old
+ new

@@ -148,10 +148,10 @@ results = tags(class_name) if index == 'last()' index = results.length index -= 1 if index >= 0 else - raise 'Index must be >= 1' unless index >= 1 + raise ArgumentError, 'Index must be >= 1' unless index >= 1 index -= 1 if index >= 1 end # uiautomator has issues with index/instance so calculate the index