Skip to content

Commit

Permalink
Fix now and nowms
Browse files Browse the repository at this point in the history
  • Loading branch information
Rexagon committed Sep 7, 2023
1 parent f9aa981 commit f0ca8c0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cli/src/env.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ impl Environment for SystemEnvironment {
std::time::SystemTime::now()
.duration_since(std::time::UNIX_EPOCH)
.unwrap()
.as_micros() as u64
.as_millis() as u64
}

fn get_env(&self, name: &str) -> Option<String> {
Expand Down
2 changes: 1 addition & 1 deletion src/modules/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,7 @@ impl FiftModule for BaseModule {
ctx.stack.push_int(ctx.env.now_ms() / 1000)
}

#[cmd(name = "now_ms")]
#[cmd(name = "nowms")]
fn interpret_now_ms(ctx: &mut Context) -> Result<()> {
ctx.stack.push_int(ctx.env.now_ms())
}
Expand Down

0 comments on commit f0ca8c0

Please sign in to comment.