[icinga-checkins] icinga.org: icinga2-migration/master: Fix custom attribute vars

git at icinga.org git at icinga.org
Tue Jun 10 23:32:42 CEST 2014


Module: icinga2-migration
Branch: master
Commit: 28141b66114bc0ef0f5ed8bffa4ac74594084935
URL:    https://git.icinga.org/?p=icinga2-migration.git;a=commit;h=28141b66114bc0ef0f5ed8bffa4ac74594084935

Author: Michael Friedrich <michael.friedrich at gmail.com>
Date:   Tue Jun 10 23:32:27 2014 +0200

Fix custom attribute vars

---

 modules/conftool/library/Conftool/Icinga2/Icinga2ObjectDefinition.php |    1 +
 1 file changed, 1 insertion(+)

diff --git a/modules/conftool/library/Conftool/Icinga2/Icinga2ObjectDefinition.php b/modules/conftool/library/Conftool/Icinga2/Icinga2ObjectDefinition.php
index 127adc8..4d6fa94 100644
--- a/modules/conftool/library/Conftool/Icinga2/Icinga2ObjectDefinition.php
+++ b/modules/conftool/library/Conftool/Icinga2/Icinga2ObjectDefinition.php
@@ -189,6 +189,7 @@ class Icinga2ObjectDefinition
 
         //custom vars
         foreach ($object->getCustomVars() as $key => $value) {
+            $key = substr($key, 1); //drop _
             $this->vars($key, $value);
         }
     }



More information about the icinga-checkins mailing list