diff options
author | dakkar <dakkar@thenautilus.net> | 2024-02-03 16:17:04 +0000 |
---|---|---|
committer | dakkar <dakkar@thenautilus.net> | 2024-02-03 16:17:04 +0000 |
commit | dea78a04c1d6087054d7540db4ae77357484317e (patch) | |
tree | 5f2ec8a3c0d6a8c9b501018cf545e5f280fead19 /lib/WebService/TFL | |
parent | show more than 1 bus stop (diff) | |
download | HomePanel-dea78a04c1d6087054d7540db4ae77357484317e.tar.gz HomePanel-dea78a04c1d6087054d7540db4ae77357484317e.tar.bz2 HomePanel-dea78a04c1d6087054d7540db4ae77357484317e.zip |
remote redundant line name from status reason
Diffstat (limited to 'lib/WebService/TFL')
-rw-r--r-- | lib/WebService/TFL/TubeStatus/Response/LineStatus.pm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/WebService/TFL/TubeStatus/Response/LineStatus.pm b/lib/WebService/TFL/TubeStatus/Response/LineStatus.pm index 2e8e22b..69ddf20 100644 --- a/lib/WebService/TFL/TubeStatus/Response/LineStatus.pm +++ b/lib/WebService/TFL/TubeStatus/Response/LineStatus.pm @@ -17,6 +17,9 @@ has reason => ( sub new_from_response { my ($class,$response_data) = @_; + $response_data->{reason} =~ s{\A .+? : \s*}{}x + if $response_data->{reason}; + return $class->new($response_data); } |