From 0ab880d162ba0cfd5a573aa1978d103f9cb0d1bc Mon Sep 17 00:00:00 2001 From: Adrian Reber Date: Thu, 19 Dec 2024 09:00:17 +0100 Subject: [PATCH] Update chrono to 0.4.39 Signed-off-by: Adrian Reber --- Cargo.lock | 6 +++--- Cargo.toml | 2 +- src/bin/mirrorlist-server.rs | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index a3c7b41..7201784 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -127,16 +127,16 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "chrono" -version = "0.4.31" +version = "0.4.39" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f2c685bad3eb3d45a01354cedb7d5faa66194d1d58ba6e267a8de788f79db38" +checksum = "7e36cc9d416881d2e24f9a963be5fb1cd90966419ac844274161d10488b3e825" dependencies = [ "android-tzdata", "iana-time-zone", "js-sys", "num-traits", "wasm-bindgen", - "windows-targets 0.48.0", + "windows-targets 0.52.6", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index def896e..e3c638d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,7 +11,7 @@ lto = true hyper = { version = "0.14", features = ["server", "http1", "http2", "runtime"] } log = "0.4" pretty_env_logger = "0.5" -chrono = "0.4" +chrono = "0.4.39" protobuf = "3.7.1" url = "2.5.4" regex = "1" diff --git a/src/bin/mirrorlist-server.rs b/src/bin/mirrorlist-server.rs index 1570069..0cf98c1 100644 --- a/src/bin/mirrorlist-server.rs +++ b/src/bin/mirrorlist-server.rs @@ -1262,7 +1262,7 @@ async fn main() { } }); - if let Some(t) = chrono::NaiveDateTime::from_timestamp_opt(mirrorlist.Time.unwrap() as i64, 0) { + if let Some(t) = chrono::DateTime::from_timestamp(mirrorlist.Time.unwrap() as i64, 0) { info!("Database creation time {} ({}) ", t, &mirrorlist.Time.unwrap()); }