Skip to content

Commit 3eaa27c

Browse files
committed
Un-hide a few elidded lifetimes
1 parent 6a2492e commit 3eaa27c

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

crates/config/src/sections/secrets.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ impl KeyConfig {
149149
/// Returns the password in case any is provided.
150150
///
151151
/// If `password_file` was given, the password is read from that file.
152-
async fn password(&self) -> anyhow::Result<Option<Cow<[u8]>>> {
152+
async fn password(&self) -> anyhow::Result<Option<Cow<'_, [u8]>>> {
153153
Ok(match &self.password {
154154
Some(Password::File(path)) => Some(Cow::Owned(tokio::fs::read(path).await?)),
155155
Some(Password::Value(password)) => Some(Cow::Borrowed(password.as_bytes())),
@@ -160,7 +160,7 @@ impl KeyConfig {
160160
/// Returns the key.
161161
///
162162
/// If `key_file` was given, the key is read from that file.
163-
async fn key(&self) -> anyhow::Result<Cow<[u8]>> {
163+
async fn key(&self) -> anyhow::Result<Cow<'_, [u8]>> {
164164
Ok(match &self.key {
165165
Key::File(path) => Cow::Owned(tokio::fs::read(path).await?),
166166
Key::Value(key) => Cow::Borrowed(key.as_bytes()),

crates/data-model/src/oauth2/authorization_grant.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ impl std::ops::Deref for AuthorizationGrant {
173173

174174
impl AuthorizationGrant {
175175
#[must_use]
176-
pub fn parse_login_hint(&self, homeserver: &str) -> LoginHint {
176+
pub fn parse_login_hint(&self, homeserver: &str) -> LoginHint<'_> {
177177
let Some(login_hint) = &self.login_hint else {
178178
return LoginHint::None;
179179
};

crates/oidc-client/tests/it/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ fn keystore(alg: &JsonWebSignatureAlg) -> Keystore {
7474
}
7575

7676
/// Generate an ID token.
77-
fn id_token(issuer: &str) -> (IdToken, PublicJsonWebKeySet) {
77+
fn id_token(issuer: &str) -> (IdToken<'_>, PublicJsonWebKeySet) {
7878
let signing_alg = ID_TOKEN_SIGNING_ALG;
7979

8080
let keystore = keystore(&signing_alg);

crates/oidc-client/tests/it/requests/jose.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ fn id_token(
3434
issuer: &str,
3535
flag: Option<IdTokenFlag>,
3636
auth_time: Option<DateTime<Utc>>,
37-
) -> (IdToken, PublicJsonWebKeySet) {
37+
) -> (IdToken<'_>, PublicJsonWebKeySet) {
3838
let signing_alg = ID_TOKEN_SIGNING_ALG;
3939

4040
let keystore = keystore(&signing_alg);

0 commit comments

Comments
 (0)