Fix edge case with iframe switching
Fix edge case with iframe switching
- Only scroll to iframes before switching to them if the identifier is a string
- An iframe identifier can be a string (selector, name, or id), an int (index), or a web element, but the
self.scroll_to(selector)
method expects a string selector for finding the element first. self.switch_to_frame(frame)
is the method for switching to an iframe.
(The iframe identifier can be a selector, an index, an id, a name, or a web element, but scrolling to the iframe first will only occur for visible iframes with a string selector.)