From 59fe43fe1444a5a9edbe3bdc8761bd079176f6ea Mon Sep 17 00:00:00 2001 From: Martin Domke Date: Fri, 10 May 2024 14:58:30 +0200 Subject: [PATCH] chore: Use Python 3.8 compliant type expression in cast --- schwifty/bban.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/schwifty/bban.py b/schwifty/bban.py index eaa053d..0916350 100644 --- a/schwifty/bban.py +++ b/schwifty/bban.py @@ -4,6 +4,7 @@ from random import Random from typing import Any from typing import cast +from typing import Dict from rstr import Rstr @@ -170,7 +171,7 @@ def random(cls, country_code: str = "", random: Random | None = None, **values: if random is None: random = Random() # noqa: S311 - banks_by_country = cast(dict[str, Any], registry.get("country")) + banks_by_country = cast(Dict[str, Any], registry.get("country")) if not country_code: country_code = random.choice(list(banks_by_country.keys()))