[icinga-checkins] icinga.org: icingaweb2-module-director/fiddle/mfrosch: WIP: Modify IcingaObjectsImport as modified on set

git at icinga.org git at icinga.org
Thu May 19 11:01:23 CEST 2016


Module: icingaweb2-module-director
Branch: fiddle/mfrosch
Commit: 6c5dc1ea6ae4f86c5466b8289f3c44bd3321f370
URL:    https://git.icinga.org/?p=icingaweb2-module-director.git;a=commit;h=6c5dc1ea6ae4f86c5466b8289f3c44bd3321f370

Author: Markus Frosch <lazyfrosch at icinga.org>
Date:   Thu May 19 10:55:37 2016 +0200

WIP: Modify IcingaObjectsImport as modified on set

The form currently sets array('') (Array of an empty string) - which is ignored by add(), but the object is then not been modified.

Which it technically is.

Imports can not be set empty due to this.

---

 library/Director/Objects/IcingaObjectImports.php |    1 +
 1 file changed, 1 insertion(+)

diff --git a/library/Director/Objects/IcingaObjectImports.php b/library/Director/Objects/IcingaObjectImports.php
index e8d936f..ce1ef07 100644
--- a/library/Director/Objects/IcingaObjectImports.php
+++ b/library/Director/Objects/IcingaObjectImports.php
@@ -105,6 +105,7 @@ class IcingaObjectImports implements Iterator, Countable, IcingaConfigRenderer
         }
 
         $this->imports = array();
+        $this->modified = true;
         return $this->add($import);
     }
 



More information about the icinga-checkins mailing list