Fix to simplify make_date calls

This commit is contained in:
Ilia Ross
2024-06-16 01:48:14 +03:00
parent 37451ad905
commit 458916b4d8
3 changed files with 4 additions and 4 deletions

View File

@@ -4412,10 +4412,10 @@ elsif ($line =~ /^END:VEVENT/) {
# Try to add local 'when (period)'
my $dtstart_local_obj =
$event{'_obj_dtstart_local_time'} =
make_date($event{'dtstart_local_timestamp'}, { _ });
make_date($event{'dtstart_local_timestamp'}, { });
my $dtend_local_obj =
$event{'_obj_dtend_local_time'} =
make_date($event{'dtend_local_timestamp'}, { _ });
make_date($event{'dtend_local_timestamp'}, { });
# Build when local, e.g.:
# Tue Jun 04, 2024 04:30 PM 05:15
# PM (Asia/Nicosia +0300)

View File

@@ -2176,7 +2176,7 @@ if (!$@ && $] > 5.011) {
}
# Return fully detailed object
if (%{$opts}) {
if (ref($only)) {
# Can we get ago time
my $ago;
my $ago_secs = time() - $secs;

View File

@@ -128,7 +128,7 @@ if (!$eol_data->{'_eol_timestamp'}) {
&error_stderr("The provided data is not a valid EOL data hash reference");
return undef;
}
my $eol_date = &make_date($eol_data->{'_eol_timestamp'}, { '_' => 1 });
my $eol_date = &make_date($eol_data->{'_eol_timestamp'}, { });
if (ref($eol_date)) {
my $eol_in = sub {
my $eol_date = shift;