mirror of https://github.com/rwf2/Rocket.git
Update 'cookie' to 0.13, 'rustls' to 0.16.
This commit is contained in:
parent
31712018bb
commit
7c1b8dc9ad
|
@ -23,16 +23,16 @@ private-cookies = ["cookie/secure"]
|
|||
smallvec = "1.0"
|
||||
percent-encoding = "1"
|
||||
hyper = { version = "0.10.13", default-features = false }
|
||||
time = "0.1"
|
||||
time = "0.2.4"
|
||||
indexmap = "1.0"
|
||||
rustls = { version = "0.15", optional = true }
|
||||
rustls = { version = "0.16", optional = true }
|
||||
state = "0.4"
|
||||
cookie = { version = "0.12", features = ["percent-encode"] }
|
||||
cookie = { version = "0.13", features = ["percent-encode"] }
|
||||
pear = "0.1"
|
||||
unicode-xid = "0.2"
|
||||
|
||||
[dependencies.hyper-sync-rustls]
|
||||
version = "=0.3.0-rc.5"
|
||||
version = "=0.3.0-rc.6"
|
||||
features = ["server"]
|
||||
optional = true
|
||||
|
||||
|
|
|
@ -362,7 +362,7 @@ impl Cookies<'_> {
|
|||
}
|
||||
|
||||
if cookie.expires().is_none() {
|
||||
cookie.set_expires(time::now() + time::Duration::weeks(1));
|
||||
cookie.set_expires(time::OffsetDateTime::now() + time::Duration::weeks(1));
|
||||
}
|
||||
|
||||
if cookie.same_site().is_none() {
|
||||
|
|
|
@ -31,7 +31,7 @@ log = "0.4"
|
|||
toml = "0.4.7"
|
||||
num_cpus = "1.0"
|
||||
state = "0.4.1"
|
||||
time = "0.1"
|
||||
time = "0.2.4"
|
||||
memchr = "2" # TODO: Use pear instead.
|
||||
base64 = "0.11"
|
||||
base16 = "0.2"
|
||||
|
|
|
@ -414,7 +414,7 @@ impl<'c> LocalRequest<'c> {
|
|||
// with the changes reflected by `response`.
|
||||
if let Some(ref jar) = client.cookies {
|
||||
let mut jar = jar.write().expect("LocalRequest::_dispatch() write lock");
|
||||
let current_time = time::now();
|
||||
let current_time = time::OffsetDateTime::now();
|
||||
for cookie in response.cookies() {
|
||||
if let Some(expires) = cookie.expires() {
|
||||
if expires <= current_time {
|
||||
|
|
Loading…
Reference in New Issue