Skip to content

Commit

Permalink
fix: invalid auth error code
Browse files Browse the repository at this point in the history
  • Loading branch information
raimundo-henriques committed May 16, 2024
1 parent 15d25f5 commit b92fae9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion endpoint/src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ impl<'r, 'o: 'r> Responder<'r, 'o> for OAuth2ErrorMessage {
fn respond_to(self, request: &'r Request<'_>) -> response::Result<'o> {
Response::build()
.merge(Json(self).respond_to(request)?)
.status(Status::Unauthorized)
.status(Status::BadRequest)
.ok()
}
}
Expand Down
2 changes: 1 addition & 1 deletion endpoint/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ fn oauth2_create_token(
} else {
Either::Right(error::OAuth2ErrorMessage {
error_description: "Invalid client credentials",
error: "unauthorized_client",
error: "invalid_client",
})
}
}
Expand Down

0 comments on commit b92fae9

Please sign in to comment.