Skip to content

Commit

Permalink
Keep 3.9 support, in utils too
Browse files Browse the repository at this point in the history
  • Loading branch information
mgcth committed Apr 6, 2024
1 parent 97df311 commit bddcea7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/smhi/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import logging
from datetime import datetime
from typing import Union

import arrow
import requests
Expand Down Expand Up @@ -34,7 +35,7 @@ def get_request(url: str) -> requests.Response:
return response


def format_datetime(test_time: str | datetime) -> str:
def format_datetime(test_time: Union[str, datetime]) -> str:
"""Format str and datetime to accepected time formats.
Args:
Expand Down

0 comments on commit bddcea7

Please sign in to comment.