mirror of
https://github.com/tokio-rs/axum.git
synced 2025-03-08 08:56:24 +01:00
Upgrade cookie dependency to 0.18
… and replace uses of the deprecated Cookie::named fn.
This commit is contained in:
parent
92253fe7b3
commit
fd7fd9fa71
4 changed files with 5 additions and 5 deletions
|
@ -52,7 +52,7 @@ tower-service = "0.3"
|
|||
|
||||
# optional dependencies
|
||||
axum-macros = { path = "../axum-macros", version = "0.3.7", optional = true }
|
||||
cookie = { package = "cookie", version = "0.17", features = ["percent-encode"], optional = true }
|
||||
cookie = { package = "cookie", version = "0.18.0", features = ["percent-encode"], optional = true }
|
||||
form_urlencoded = { version = "1.1.0", optional = true }
|
||||
headers = { version = "0.3.8", optional = true }
|
||||
multer = { version = "2.0.0", optional = true }
|
||||
|
|
|
@ -168,7 +168,7 @@ impl CookieJar {
|
|||
/// use axum::response::IntoResponse;
|
||||
///
|
||||
/// async fn handle(jar: CookieJar) -> CookieJar {
|
||||
/// jar.remove(Cookie::named("foo"))
|
||||
/// jar.remove(Cookie::from("foo"))
|
||||
/// }
|
||||
/// ```
|
||||
#[must_use]
|
||||
|
@ -250,7 +250,7 @@ mod tests {
|
|||
}
|
||||
|
||||
async fn remove_cookie(jar: $jar) -> impl IntoResponse {
|
||||
jar.remove(Cookie::named("key"))
|
||||
jar.remove(Cookie::from("key"))
|
||||
}
|
||||
|
||||
let state = AppState {
|
||||
|
|
|
@ -216,7 +216,7 @@ impl<K> PrivateCookieJar<K> {
|
|||
/// use axum::response::IntoResponse;
|
||||
///
|
||||
/// async fn handle(jar: PrivateCookieJar) -> PrivateCookieJar {
|
||||
/// jar.remove(Cookie::named("foo"))
|
||||
/// jar.remove(Cookie::from("foo"))
|
||||
/// }
|
||||
/// ```
|
||||
#[must_use]
|
||||
|
|
|
@ -234,7 +234,7 @@ impl<K> SignedCookieJar<K> {
|
|||
/// use axum::response::IntoResponse;
|
||||
///
|
||||
/// async fn handle(jar: SignedCookieJar) -> SignedCookieJar {
|
||||
/// jar.remove(Cookie::named("foo"))
|
||||
/// jar.remove(Cookie::from("foo"))
|
||||
/// }
|
||||
/// ```
|
||||
#[must_use]
|
||||
|
|
Loading…
Add table
Reference in a new issue