Skip to content

Commit

Permalink
Merge branch 'v0.2.1' of https://github.com/zincware/znsocket into v0…
Browse files Browse the repository at this point in the history
….2.1
  • Loading branch information
PythonFZ committed Oct 29, 2024
2 parents a62d47a + 3123baf commit c840b3f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions znsocket/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ def __init__(
if callbacks:
self._callbacks.update(callbacks)

def __getitem__(self, key: str|float|int) -> t.Any:
def __getitem__(self, key: str | float | int) -> t.Any:
value = self.redis.hget(self.key, json.dumps(key))
if value is None:
raise KeyError(key) # TODO: items can not be None?
Expand All @@ -298,7 +298,7 @@ def __getitem__(self, key: str|float|int) -> t.Any:
value = Dict(r=self.redis, key=key)
return value

def __setitem__(self, key: str|float|int, value: t.Any) -> None:
def __setitem__(self, key: str | float | int, value: t.Any) -> None:
if isinstance(value, List):
value = f"znsocket.List:{value.key}"
if isinstance(value, Dict):
Expand Down

0 comments on commit c840b3f

Please sign in to comment.