fixed form error.
This commit is contained in:
parent
617a7b9698
commit
fec3edd516
1 changed files with 1 additions and 0 deletions
|
|
@ -646,6 +646,7 @@ A string in the format of YYYY-MM-DD or YYYY-MM-DD HH:MM:SS.
|
||||||
|
|
||||||
sub setToEpoch {
|
sub setToEpoch {
|
||||||
my $set = shift;
|
my $set = shift;
|
||||||
|
return undef unless defined $set;
|
||||||
my $parser = DateTime::Format::Strptime->new( pattern => '%Y-%m-%d %H:%M:%S' );
|
my $parser = DateTime::Format::Strptime->new( pattern => '%Y-%m-%d %H:%M:%S' );
|
||||||
my $dt = $parser->parse_datetime($set);
|
my $dt = $parser->parse_datetime($set);
|
||||||
# in epochToSet we apply the user's time zone, so now we have to remove it.
|
# in epochToSet we apply the user's time zone, so now we have to remove it.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue