Skip to content

Commit

Permalink
Use explicit request for json return data during OAuth token request.
Browse files Browse the repository at this point in the history
Some OAuth providers like GitHub default to return web encoded strings
instead of JSON. This enables the use of cratery with GitHub Enterprise
as OAuth provider.

Signed-off-by: Diego Dompe <[email protected]>
  • Loading branch information
ddompe authored and woutersl committed Nov 27, 2024
1 parent 26b5755 commit 099b34a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/services/database/users.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ impl Database {
("client_id", &configuration.oauth_client_id),
("client_secret", &configuration.oauth_client_secret),
])
.header(reqwest::header::ACCEPT, "application/json")
.send()
.await?;
if !response.status().is_success() {
Expand Down

0 comments on commit 099b34a

Please sign in to comment.