summaryrefslogtreecommitdiff
path: root/lib/DBInfoscreen/Controller
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2020-10-12 19:31:39 +0200
committerDaniel Friesel <derf@finalrewind.org>2020-10-12 19:31:39 +0200
commit951581a95a95d43e59ebec8588e00c7f0f37306d (patch)
tree7dd31dfc5b471297f05dbfd8c5e471faa22dd864 /lib/DBInfoscreen/Controller
parent6807eba76b0c9d51db0b33c873f2b1a77ad53be7 (diff)
do template fallback before performing legacy check3.4.2
Diffstat (limited to 'lib/DBInfoscreen/Controller')
-rw-r--r--lib/DBInfoscreen/Controller/Stationboard.pm8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/DBInfoscreen/Controller/Stationboard.pm b/lib/DBInfoscreen/Controller/Stationboard.pm
index d4217ea..2bf2bcb 100644
--- a/lib/DBInfoscreen/Controller/Stationboard.pm
+++ b/lib/DBInfoscreen/Controller/Stationboard.pm
@@ -213,6 +213,10 @@ sub handle_request {
$self->stash( title => 'DBF' );
$self->stash( version => $dbf_version );
+ if ( not( $template ~~ [qw[app infoscreen json multi single text]] ) ) {
+ $template = 'app';
+ }
+
if ( defined $station and $station =~ s{ [.] txt $ }{}x ) {
$template = 'text';
$self->param( station => $station );
@@ -240,10 +244,6 @@ sub handle_request {
$template = 'json';
}
- if ( not( $template ~~ [qw[app infoscreen json multi single text]] ) ) {
- $template = 'app';
- }
-
$self->param( mode => $template );
if ( not $station ) {