Skip to content

Commit

Permalink
fix user/auth headers (#836)
Browse files Browse the repository at this point in the history
One thing to note is that when no `user` is provided, its header does
not appear (as expected). When no `auth` is provided, its header appears
like so:
```
'x-verified-user-data': '{}'
```
  • Loading branch information
rolyatmax authored Nov 4, 2024
1 parent 1cc90d9 commit 1eaeee3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plane/src/database/backend.rs
Original file line number Diff line number Diff line change
Expand Up @@ -405,8 +405,8 @@ impl<'a> BackendDatabase<'a> {
secret_token: SecretToken::from(result.secret_token),
cluster: ClusterName::from_str(&result.cluster)
.map_err(|_| sqlx::Error::Decode("Failed to decode cluster name.".into()))?,
user: None,
user_data: None,
user: result.username,
user_data: Some(result.auth),
subdomain: result
.subdomain
.map(Subdomain::try_from)
Expand Down

0 comments on commit 1eaeee3

Please sign in to comment.