Skip to content

Commit a162e8a

Browse files
committed
Fix type anno for Python 3.9
1 parent 68bc434 commit a162e8a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

timm/models/_hub.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -535,7 +535,7 @@ def _get_safe_alternatives(filename: str) -> Iterable[str]:
535535
yield filename[:-4] + ".safetensors"
536536

537537

538-
def _get_license_from_hf_hub(model_id: str | None, hf_hub_id: str | None) -> str | None:
538+
def _get_license_from_hf_hub(model_id: Optional[str], hf_hub_id: Optional[str]) -> Optional[str]:
539539
"""Retrieve license information for a model from Hugging Face Hub.
540540
541541
Fetches the license field from the model card metadata on Hugging Face Hub

0 commit comments

Comments
 (0)