diff options
author | David Phillips <david@sighup.nz> | 2018-06-26 21:39:33 +1200 |
---|---|---|
committer | David Phillips <david@sighup.nz> | 2018-06-26 21:39:33 +1200 |
commit | ca1ba1ad6825e93bf6be91317ffdf57d076ad798 (patch) | |
tree | d0342004d20dde1175389cd8f728aa21158b50cf /Plugin/Timezone.pm | |
parent | 549ac4f97e0a70238006cc7b4d4ff752f281b930 (diff) | |
download | idalius-ca1ba1ad6825e93bf6be91317ffdf57d076ad798.tar.xz |
Use tidier format for time
Diffstat (limited to 'Plugin/Timezone.pm')
-rw-r--r-- | Plugin/Timezone.pm | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Plugin/Timezone.pm b/Plugin/Timezone.pm index eaea907..60a0f34 100644 --- a/Plugin/Timezone.pm +++ b/Plugin/Timezone.pm @@ -30,9 +30,10 @@ sub time { my $nick = $arguments[0]; if (grep {$_ eq $nick} @known_zones) { - my $d = DateTime->now(); + my $d = DateTime->now(); $d->set_time_zone($config{timezone}->{$nick}); - return "$requester: $nick\'s clock reads $d"; + my $timestr = $d->strftime("%Y-%m-%d %H:%M %Z"); + return "$requester: $nick\'s clock reads $timestr"; } else { return "$requester: I don't know what timezone $nick is in"; } |