summaryrefslogtreecommitdiff
path: root/lib/Travel/Status/DE/IRIS.pm
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2015-04-18 23:03:15 +0200
committerDaniel Friesel <derf@finalrewind.org>2015-04-18 23:03:15 +0200
commitd629ad663f6195287dd31f0204f9d3a163b0869c (patch)
tree0812c04d38ede3d9e56a8bab7a774947946069e1 /lib/Travel/Status/DE/IRIS.pm
parentef40feb961f363029d98524b62a38a977823bb2b (diff)
wing_id only uses two thirds of the train_id. now wing detection actually works.
Diffstat (limited to 'lib/Travel/Status/DE/IRIS.pm')
-rw-r--r--lib/Travel/Status/DE/IRIS.pm3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/Travel/Status/DE/IRIS.pm b/lib/Travel/Status/DE/IRIS.pm
index da39a7c..34f7fc4 100644
--- a/lib/Travel/Status/DE/IRIS.pm
+++ b/lib/Travel/Status/DE/IRIS.pm
@@ -13,7 +13,6 @@ use DateTime;
use Encode qw(encode decode);
use List::Util qw(first);
use LWP::UserAgent;
-use Scalar::Util qw(weaken);
use Travel::Status::DE::IRIS::Result;
use XML::LibXML;
@@ -298,7 +297,7 @@ sub get_realtime {
sub get_result_by_id {
my ( $self, $id ) = @_;
- my $res = first { $_->{raw_id} eq $id } $self->results;
+ my $res = first { $_->wing_id eq $id } @{ $self->{results} };
return $res;
}