summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2009-08-09 11:47:54 +0200
committerYorhel <git@yorhel.nl>2009-08-09 11:47:54 +0200
commit500a9c017f3d033fa4eaa336c5d116bcbe31cf70 (patch)
tree1f49a2f6dc466631fa806cb8d45f2db662281cca
parent6a7ce876111ba59c33c332c947fb3644636ef650 (diff)
Multi::IRC: Fix double-notify bug
timestamptz data types have sub-second precision, but we use time() with second precision for comparing, resulting in false positives. Using Time::HiRes::time should give the same precision as PostgreSQL's NOW(), so things should be working fine now. It's still a bad idea to use Multi's time instead of a PostgreSQL value for comparing... should really think of a clean way of fixing this.
-rw-r--r--lib/Multi/IRC.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Multi/IRC.pm b/lib/Multi/IRC.pm
index ff122405..63acd0a9 100644
--- a/lib/Multi/IRC.pm
+++ b/lib/Multi/IRC.pm
@@ -15,6 +15,7 @@ use POE qw|
|;
use POE::Component::IRC::Common ':ALL';
use URI::Escape 'uri_escape_utf8';
+use Time::HiRes 'time';
use constant {
USER => ARG0,