Fix ruff rules ISC flake8-implicit-str-concat (#8892)

This commit is contained in:
Christian Clauss
2023-07-28 18:53:09 +02:00
committed by GitHub
parent b77e6adf3a
commit dbaff34572
6 changed files with 128 additions and 133 deletions

View File

@ -22,9 +22,7 @@ def is_sri_lankan_phone_number(phone: str) -> bool:
False
"""
pattern = re.compile(
r"^(?:0|94|\+94|0{2}94)" r"7(0|1|2|4|5|6|7|8)" r"(-| |)" r"\d{7}$"
)
pattern = re.compile(r"^(?:0|94|\+94|0{2}94)7(0|1|2|4|5|6|7|8)(-| |)\d{7}$")
return bool(re.search(pattern, phone))