From 0ab1704f23b645d347c830b10d2d174368abc94d Mon Sep 17 00:00:00 2001 From: HitBlast Date: Mon, 12 Jun 2023 12:44:53 +0600 Subject: [PATCH] improved static types --- avro/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/avro/main.py b/avro/main.py index 48dba68..31dfd85 100755 --- a/avro/main.py +++ b/avro/main.py @@ -30,7 +30,7 @@ # Import third-party modules. import re -from typing import Any, Dict, List, Union +from typing import Any, Dict, List, Optional, Union # Import local modules. from . import config @@ -296,7 +296,7 @@ def reverse_with_rules(cursor: int, fixed_text: str, text_reversed: str) -> str: return text_reversed if not text_reversed else text_reversed + added_suffix -def process_rules(rules: Dict[str, Any], fixed_text: str, cur: int = 0, cur_end: int = 1) -> Union[Any, None]: +def process_rules(rules: Dict[str, Any], fixed_text: str, cur: int = 0, cur_end: int = 1) -> Optional[str]: ''' ### Process rules matched in pattern and returns suitable replacement.