]> git.proxmox.com Git - pve-manager-legacy.git/commitdiff
pveproxy: fix detecting mobile if enforced
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Sun, 28 May 2023 16:24:53 +0000 (18:24 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Sun, 28 May 2023 16:25:24 +0000 (18:25 +0200)
Fixes: 38b07c13b ("proxy: cleanup getting index method")
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
PVE/Service/pveproxy.pm

index 623440213ae86a03eda074dd07f00f06eda8d489..839a37c79eb4f986f8f8943dda65e26ea8a29cc2 100755 (executable)
@@ -219,7 +219,7 @@ sub get_index {
        $lang = $dc_conf->{language} // 'en';
     }
 
-    my $mobile = is_phone($r->header('User-Agent')) && (!defined($args->{mobile}) || $args->{mobile});
+    my $mobile = (is_phone($r->header('User-Agent')) && (!defined($args->{mobile}) || $args->{mobile})) || $args->{mobile};
 
     my $novnc = defined($args->{console}) && $args->{novnc};
     my $xtermjs = defined($args->{console}) && $args->{xtermjs};