mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-27 10:59:53 +00:00
Return 404 from API if no user is found
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
This commit is contained in:
parent
7e2d1fefc4
commit
b3038c2de9
1 changed files with 1 additions and 1 deletions
|
@ -135,7 +135,7 @@ async fn get_user(
|
|||
.db
|
||||
.get_user_by_github_login(&login)
|
||||
.await?
|
||||
.ok_or_else(|| anyhow!("user not found"))?;
|
||||
.ok_or_else(|| Error::Http(StatusCode::NOT_FOUND, "User not found".to_string()))?;
|
||||
Ok(Json(user))
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue