better
This commit is contained in:
parent
eb9d4ba546
commit
6ebef4e469
1 changed files with 1 additions and 5 deletions
|
|
@ -96,12 +96,8 @@ The number of seconds since January 1, 1970.
|
||||||
=cut
|
=cut
|
||||||
|
|
||||||
sub epochToArray {
|
sub epochToArray {
|
||||||
my $timeZone = $session{user}{timeZone} || "America/Chicago";
|
|
||||||
use DateTime;
|
use DateTime;
|
||||||
my $dt = DateTime->from_epoch( epoch =>shift, time_zone=>$timeZone);
|
return split / /, DateTime->from_epoch( epoch =>shift, time_zone=>{$session{user}{timeZone} || "America/Chicago"})->strftime("%Y %m %d %H %M %S");
|
||||||
my @date = split / /, $dt->strftime("%Y %m %d %H %M %S");
|
|
||||||
@date = map {$_ += 0} @date;
|
|
||||||
return @date;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue