View | Details | Raw Unified | Return to bug 24850
Collapse All | Expand All

(-)a/Koha/DateUtils.pm (-2 / +3 lines)
Lines 54-60 sub dt_from_string { Link Here
54
    return if $date_string and $date_string =~ m|^0000-0|;
54
    return if $date_string and $date_string =~ m|^0000-0|;
55
55
56
    my $do_fallback = defined($date_format) ? 0 : 1;
56
    my $do_fallback = defined($date_format) ? 0 : 1;
57
    $tz = C4::Context->tz unless $tz;;
57
    my $server_tz = C4::Context->tz;
58
    $tz = C4::Context->tz unless $tz;
58
59
59
    return DateTime->now( time_zone => $tz ) unless $date_string;
60
    return DateTime->now( time_zone => $tz ) unless $date_string;
60
61
Lines 195-200 sub dt_from_string { Link Here
195
            ( $dt_params{year} < 9999 ? ( time_zone => $tz ) : () ),
196
            ( $dt_params{year} < 9999 ? ( time_zone => $tz ) : () ),
196
        );
197
        );
197
    }
198
    }
199
    $dt->set_time_zone($server_tz);
198
    return $dt;
200
    return $dt;
199
}
201
}
200
202
201
- 

Return to bug 24850