From ec45cf264d5b964daab04e2ea86573469f6d4f6f Mon Sep 17 00:00:00 2001 From: phl0 Date: Tue, 19 Jul 2016 14:04:24 +0200 Subject: [PATCH] Only initialize YSF infos if YSFGateway is enabled --- include/functions.php | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/include/functions.php b/include/functions.php index 5b75a2d..1291706 100644 --- a/include/functions.php +++ b/include/functions.php @@ -499,8 +499,10 @@ $logLinesMMDVM = getMMDVMLog(); $reverseLogLinesMMDVM = $logLinesMMDVM; array_multisort($reverseLogLinesMMDVM,SORT_DESC); $lastHeard = getLastHeard($reverseLogLinesMMDVM); -$YSFGatewayconfigs = getYSFGatewayConfig(); -$logLinesYSFGateway = getYSFGatewayLog(); -$reverseLogLinesYSFGateway = $logLinesYSFGateway; -array_multisort($reverseLogLinesYSFGateway,SORT_DESC); +if (defined("ENABLEYSFGATEWAY")) { + $YSFGatewayconfigs = getYSFGatewayConfig(); + $logLinesYSFGateway = getYSFGatewayLog(); + $reverseLogLinesYSFGateway = $logLinesYSFGateway; + array_multisort($reverseLogLinesYSFGateway,SORT_DESC); +} ?>