client-api: Use borrowed types in refresh_token::v3::Request

This commit is contained in:
Kévin Commaille 2022-07-30 14:49:28 +02:00 committed by Kévin Commaille
parent 8e2c4b5cb7
commit 90f9463c1a

View File

@ -43,7 +43,7 @@ pub mod v3 {
request: {
/// The refresh token.
pub refresh_token: String,
pub refresh_token: &'a str,
}
response: {
@ -70,9 +70,9 @@ pub mod v3 {
error: crate::Error
}
impl Request {
impl<'a> Request<'a> {
/// Creates a new `Request` with the given refresh token.
pub fn new(refresh_token: String) -> Self {
pub fn new(refresh_token: &'a str) -> Self {
Self { refresh_token }
}
}