Skip to content

Commit

Permalink
remove unused type hints
Browse files Browse the repository at this point in the history
  • Loading branch information
zxdavb committed Oct 27, 2024
1 parent 0278ac6 commit 67fb1d0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/evohomeasync2/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ async def _write(filename: TextIOWrapper | Any, content: str) -> None:
"""Write to a file, async if possible and sync otherwise."""

try:
async with aiofiles.open(filename.name, "w") as fp: # type: ignore[call-overload]
async with aiofiles.open(filename.name, "w") as fp:
await fp.write(content)
except TypeError: # if filename is sys.stdout:
filename.write(content)
Expand Down Expand Up @@ -358,7 +358,7 @@ async def set_schedules(
evo: EvohomeClient = ctx.obj[SZ_EVO]

# will TypeError if filename is sys.stdin
async with aiofiles.open(filename.name) as fp: # type: ignore[call-overload]
async with aiofiles.open(filename.name) as fp:
content = await fp.read()

success = await _get_tcs(evo, loc_idx).set_schedules(json.loads(content))
Expand Down

0 comments on commit 67fb1d0

Please sign in to comment.