[icinga-checkins] icinga.org: icinga-web/master: Fixed accessconfig to prefer conf. d values over module access values

git at icinga.org git at icinga.org
Tue Oct 9 12:51:10 CEST 2012


Module: icinga-web
Branch: master
Commit: b5ef0265409bde45d4bb9968b4e82b39fd405384
URL:    https://git.icinga.org/?p=icinga-web.git;a=commit;h=b5ef0265409bde45d4bb9968b4e82b39fd405384

Author: Jannis Mosshammer <jannis.mosshammer at netways.de>
Date:   Tue Oct  9 12:50:18 2012 +0200

Fixed accessconfig to prefer conf.d values over module access values
(fixes #3198)

---

 app/modules/Api/lib/config/AccessConfig.class.php |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/app/modules/Api/lib/config/AccessConfig.class.php b/app/modules/Api/lib/config/AccessConfig.class.php
old mode 100644
new mode 100755
index 89bfd1c..63fa41c
--- a/app/modules/Api/lib/config/AccessConfig.class.php
+++ b/app/modules/Api/lib/config/AccessConfig.class.php
@@ -135,8 +135,9 @@ final class AccessConfig {
         $host = self::getHostByName($host);
 
         if(isset($host[$type][$file]))
-            return $host[$type][$file];
-
+            $file = $host[$type][$file];
+        if(is_array($file))
+            $file = $file[0];
         return $file; 
     }
 





More information about the icinga-checkins mailing list