From f041514bfeacfe65d773a9d3a6300e31ad38c905 Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Thu, 14 Mar 2019 16:10:30 +0100 Subject: [locationinfo] Add black/whitelist stuff for URL panels --- modules-available/locationinfo/inc/infopanel.inc.php | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'modules-available/locationinfo/inc/infopanel.inc.php') diff --git a/modules-available/locationinfo/inc/infopanel.inc.php b/modules-available/locationinfo/inc/infopanel.inc.php index fdc253f0..7b0c6fe0 100644 --- a/modules-available/locationinfo/inc/infopanel.inc.php +++ b/modules-available/locationinfo/inc/infopanel.inc.php @@ -19,13 +19,14 @@ class InfoPanel return false; } + $config = LocationInfo::defaultPanelConfig($panel['paneltype']); + if ($panel['paneltype'] === 'URL') { // Shortcut for URL redirect - $config = json_decode($panel['panelconfig'], true); + $config = json_decode($panel['panelconfig'], true) + $config; return $panel['paneltype']; } - $config = LocationInfo::defaultPanelConfig($panel['paneltype']); $locations = Location::getLocationsAssoc(); $overrides = false; @@ -37,9 +38,6 @@ class InfoPanel $overrides = $json['overrides']; } unset($json['overrides']); - if (!isset($json['roomplanner'])) { - $config['roomplanner'] = false; - } $config = $json + $config; } } -- cgit v1.2.3-55-g7522