From dc4bd531a4aee036d28dfc233662ac71e4f6e7df Mon Sep 17 00:00:00 2001 From: redmatrix Date: Thu, 29 Oct 2015 15:11:41 -0700 Subject: issue #106 --- util/service_class | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'util/service_class') diff --git a/util/service_class b/util/service_class index a1a172518..d3b60a2df 100755 --- a/util/service_class +++ b/util/service_class @@ -90,11 +90,15 @@ if($argc == 2) { if($argc == 1) { load_config('service_class'); - foreach($a->config['service_class'] as $class=>$props) { - echo "$class:\n"; - $d = unserialize($props); - foreach($d as $k => $v) { - echo "\t$k = $v\n"; + if(is_array($a->config['service_class']) && $a->config['service_class']) { + foreach($a->config['service_class'] as $class=>$props) { + echo "$class:\n"; + $d = unserialize($props); + if(is_array($d) && $d) { + foreach($d as $k => $v) { + echo "\t$k = $v\n"; + } + } } } } \ No newline at end of file -- cgit v1.2.3