From 5a03deee5b37c34e19cf2e020e18ec08a5a05b89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Steffen=20Schro=CC=88der?= Date: Sat, 14 Dec 2013 23:31:19 +0100 Subject: [PATCH] Fix for non-script modes --- application/core/Configurators/ScriptSettings.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/application/core/Configurators/ScriptSettings.php b/application/core/Configurators/ScriptSettings.php index 8b8d0fe2..8cd03e35 100644 --- a/application/core/Configurators/ScriptSettings.php +++ b/application/core/Configurators/ScriptSettings.php @@ -56,6 +56,13 @@ class ScriptSettings implements ConfiguratorMenu { $this->maniaControl->client->query('GetModeScriptInfo'); $scriptInfo = $this->maniaControl->client->getResponse(); + if (isset($scriptInfo['faultCode'])) { + // Not in script mode + $label = new Label(); + $frame->add($label); + $label->setText($scriptInfo['faultString']); + return $frame; + } $scriptParams = $scriptInfo['ParamDescs']; $this->maniaControl->client->query('GetModeScriptSettings');