Skip to content

Commit 9ac12ab

Browse files
committed
Use the | operator instead of Union
1 parent 9c84475 commit 9ac12ab

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

pefile.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333
import uuid
3434
from collections import Counter, defaultdict
3535
from hashlib import md5, sha1, sha256, sha512
36-
from typing import Union
3736

3837
import ordlookup
3938

@@ -2308,7 +2307,7 @@ def is_valid_dos_filename(s):
23082307

23092308
@lru_cache(maxsize=2048)
23102309
def is_valid_function_name(
2311-
s: Union[str, bytes, bytearray], relax_allowed_characters: bool = False
2310+
s: str | bytes | bytearray, relax_allowed_characters: bool = False
23122311
) -> bool:
23132312
allowed_extra = b"._?@$()<>"
23142313
if relax_allowed_characters:

0 commit comments

Comments
 (0)