Skip to content

Commit

Permalink
fix: replaces badly formatted error message with one consistent with …
Browse files Browse the repository at this point in the history
…the other sdks
  • Loading branch information
ctran88 committed Dec 12, 2024
1 parent 263568b commit e27de27
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion passageidentity/user.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def get_by_identifier(self, identifier: str) -> PassageUser:
raise PassageError.from_response_error(e, msg) from e

if len(users) == 0:
msg = "Could not find user with identifier: {identifier}"
msg = "User not found."
raise PassageError(msg)

return self.get(users[0].id)
Expand Down
2 changes: 1 addition & 1 deletion tests/user_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def test_get_by_identifier_valid_upper_case() -> None:
def test_get_by_identifier_user_not_exist() -> None:
psg = Passage(PASSAGE_APP_ID, PASSAGE_API_KEY)

with pytest.raises(PassageError, match="Could not find user with identifier"):
with pytest.raises(PassageError, match="User not found."):
psg.user.get_by_identifier("[email protected]")


Expand Down

0 comments on commit e27de27

Please sign in to comment.