diff options
| author | Owen Jacobson <owen@grimoire.ca> | 2024-10-22 23:25:24 -0400 |
|---|---|---|
| committer | Owen Jacobson <owen@grimoire.ca> | 2024-10-22 23:25:24 -0400 |
| commit | 01f9f3549c76702fd56e58d44c5180fecddb4bfa (patch) | |
| tree | e7a64e70975a8b50bc442d28c17161b82c42c63a /src/setup | |
| parent | 214a9e6c1fd729fc2c49eb2a5d41b5651ff5bc61 (diff) | |
Sort out the naming of the various parts of an identity.
* A `cookie::Identity` (`IdentityCookie`) is a specialized CookieJar for working with identities.
* An `Identity` is a token/login pair.
I hope for this to be a bit more legible.
In service of this, `Login` is no longer extractable. You have to get an identity.
Diffstat (limited to 'src/setup')
| -rw-r--r-- | src/setup/routes/post.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/setup/routes/post.rs b/src/setup/routes/post.rs index fb2280a..f7b256e 100644 --- a/src/setup/routes/post.rs +++ b/src/setup/routes/post.rs @@ -11,15 +11,15 @@ use crate::{ login::{Login, Password}, name::Name, setup::app, - token::extract::IdentityToken, + token::extract::IdentityCookie, }; pub async fn handler( State(app): State<App>, RequestedAt(setup_at): RequestedAt, - identity: IdentityToken, + identity: IdentityCookie, Json(request): Json<Request>, -) -> Result<(IdentityToken, Json<Login>), Error> { +) -> Result<(IdentityCookie, Json<Login>), Error> { let (login, secret) = app .setup() .initial(&request.name, &request.password, &setup_at) |
