Skip to content

Commit

Permalink
Fix logging of query durations, which were off by 10x for µs precision
Browse files Browse the repository at this point in the history
Has been broken since it was originally implemented in 3d73a5d.
  • Loading branch information
mloughran committed Sep 10, 2024
1 parent c8b80ee commit 18f9c7f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/adapter/base.cr
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ abstract class Granite::Adapter::Base
elsif elapsed_time > 0.001
"#{(elapsed_time * 1_000).trunc}ms".colorize.yellow
elsif elapsed_time > 0.000_001
"#{(elapsed_time * 100_000).trunc}µs".colorize.green
"#{(elapsed_time * 1_000_000).trunc}µs".colorize.green
elsif elapsed_time > 0.000_000_001
"#{(elapsed_time * 1_000_000_000).trunc}ns".colorize.green
else
Expand Down

0 comments on commit 18f9c7f

Please sign in to comment.