Skip to content

Commit

Permalink
Change format
Browse files Browse the repository at this point in the history
  • Loading branch information
odiseo0 committed Jul 13, 2022
1 parent 8ec4576 commit 94ef8bf
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
6 changes: 4 additions & 2 deletions gotrue/_async/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
Subscription,
User,
UserAttributes,
UserAttributesDict
UserAttributesDict,
)
from .api import AsyncGoTrueAPI
from .storage import AsyncMemoryStorage, AsyncSupportedStorage
Expand Down Expand Up @@ -302,7 +302,9 @@ async def refresh_session(self) -> Session:
raise ValueError("Not logged in.")
return await self._call_refresh_token()

async def update(self, *, attributes: Union[UserAttributesDict, UserAttributes]) -> User:
async def update(
self, *, attributes: Union[UserAttributesDict, UserAttributes]
) -> User:
"""Updates user data, if there is a logged in user.
Parameters
Expand Down
2 changes: 1 addition & 1 deletion gotrue/_sync/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
Subscription,
User,
UserAttributes,
UserAttributesDict
UserAttributesDict,
)
from .api import SyncGoTrueAPI
from .storage import SyncMemoryStorage, SyncSupportedStorage
Expand Down
4 changes: 1 addition & 3 deletions tests/_async/test_client_with_auto_confirm_enabled.py
Original file line number Diff line number Diff line change
Expand Up @@ -264,9 +264,7 @@ async def test_update_user(client: AsyncGoTrueClient):
async def test_update_user_dict(client: AsyncGoTrueClient):
try:
await client.init_recover()
response = await client.update(
attributes={"data": {"hello":"world"}}
)
response = await client.update(attributes={"data": {"hello": "world"}})
assert isinstance(response, User)
assert response.id
assert response.email == email
Expand Down
2 changes: 1 addition & 1 deletion tests/_sync/test_client_with_auto_confirm_enabled.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ def test_update_user(client: SyncGoTrueClient):
def test_update_user(client: SyncGoTrueClient):
try:
client.init_recover()
response = client.update(attributes={"data":{"hello": "world"}})
response = client.update(attributes={"data": {"hello": "world"}})
assert isinstance(response, User)
assert response.id
assert response.email == email
Expand Down

0 comments on commit 94ef8bf

Please sign in to comment.