Skip to content

Commit

Permalink
update return type for get_user calls
Browse files Browse the repository at this point in the history
  • Loading branch information
jantznick committed Sep 10, 2023
1 parent 50fa8b0 commit ddeb595
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gotrue/_async/gotrue_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ async def get_session(self) -> Union[Session, None]:
else current_session
)

async def get_user(self, jwt: Union[str, None] = None) -> UserResponse:
async def get_user(self, jwt: Union[str, None] = None) -> Union[UserResponse, None]:
"""
Gets the current user details if there is an existing session.
Expand Down
2 changes: 1 addition & 1 deletion gotrue/_sync/gotrue_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ def get_session(self) -> Union[Session, None]:
else current_session
)

def get_user(self, jwt: Union[str, None] = None) -> UserResponse:
def get_user(self, jwt: Union[str, None] = None) -> Union[UserResponse, None]:
"""
Gets the current user details if there is an existing session.
Expand Down

0 comments on commit ddeb595

Please sign in to comment.