mirror of
https://github.com/chronotope/chrono.git
synced 2025-10-02 07:21:41 +00:00
Fix for test
This commit is contained in:
parent
93e6a611d6
commit
31e3e1602e
@ -3,7 +3,6 @@
|
||||
|
||||
//! The local (system) time zone.
|
||||
|
||||
#[cfg(not(all(target_arch = "wasm32", not(target_os = "wasi"), feature = "wasmbind")))]
|
||||
use oldtime;
|
||||
|
||||
use super::fixed::FixedOffset;
|
||||
@ -152,7 +151,7 @@ impl TimeZone for Local {
|
||||
let mut local = local.clone();
|
||||
// Get the offset from the js runtime
|
||||
let offset = FixedOffset::west((js_sys::Date::new_0().get_timezone_offset() as i32) * 60);
|
||||
local -= crate::Duration::seconds(offset.local_minus_utc() as i64);
|
||||
local -= oldtime::Duration::seconds(offset.local_minus_utc() as i64);
|
||||
LocalResult::Single(DateTime::from_utc(local, offset))
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user