Skip to content

Commit

Permalink
[py]: make types correct for RelativeBy initialiser
Browse files Browse the repository at this point in the history
  • Loading branch information
symonk committed Dec 31, 2022
1 parent ccf55fe commit 10a0600
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions py/selenium/webdriver/support/relative_locator.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,9 @@
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.


from typing import Dict
from typing import List
from typing import Optional
from typing import Union

from selenium.common.exceptions import WebDriverException
Expand Down Expand Up @@ -71,7 +70,7 @@ class RelativeBy:
assert "mid" in ids
"""

def __init__(self, root: Dict[By, str] = None, filters: List = None):
def __init__(self, root: Optional[Dict[Union[By, str], str]] = None, filters: Optional[List] = None):
"""
Creates a new RelativeBy object. It is preferred if you use the
`locate_with` method as this signature could change.
Expand Down

0 comments on commit 10a0600

Please sign in to comment.