mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-30 00:34:26 +01:00
Change apiKeyPrefix to apiKeyUid
This commit is contained in:
parent
a57b2d9538
commit
b9a79eb858
@ -155,8 +155,8 @@ pub mod policies {
|
||||
let token_data = decode::<Claims>(token, &dummy_key, &validation).ok()?;
|
||||
|
||||
// get token fields without validating it.
|
||||
let Claims { uid, .. } = token_data.claims;
|
||||
Some(uid)
|
||||
let Claims { api_key_uid, .. } = token_data.claims;
|
||||
Some(api_key_uid)
|
||||
}
|
||||
|
||||
fn is_keys_action(action: u8) -> bool {
|
||||
@ -250,6 +250,6 @@ pub mod policies {
|
||||
struct Claims {
|
||||
search_rules: SearchRules,
|
||||
exp: Option<i64>,
|
||||
uid: Uuid,
|
||||
api_key_uid: Uuid,
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user