Unverified Commit 2dab71fd authored by Birte Kristina Friesel's avatar Birte Kristina Friesel
Browse files

EFA->new: Add datetime option

parent 47f45a00
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -175,7 +175,8 @@ sub new {
	if ( not $opt{efa_url} ) {
		confess('service or efa_url must be specified');
	}
	my $now = DateTime->now( time_zone => $opt{time_zone} // 'Europe/Berlin' );
	my $dt = $opt{datetime}
	  // DateTime->now( time_zone => $opt{time_zone} // 'Europe/Berlin' );

	## no critic (RegularExpressions::ProhibitUnusedCapture)
	## no critic (Variables::ProhibitPunctuationVars)
@@ -789,6 +790,11 @@ B<stop> (stop/station name).

address / poi / stop name to list departures for.

=item B<datetime> => I<DateTime object>

Request departures for the date/time specified by I<DateTime object>.
Default: now.

=item B<efa_encoding> => I<encoding>

Some EFA servers do not correctly specify their response encoding. If you