[icinga-checkins] icinga.org: icinga-web/master: * Fixed reserved word issue (fixes #370)

git at icinga.org git at icinga.org
Thu Apr 15 10:59:22 CEST 2010


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

Author: Marius Hein <marius.hein at netways.de>
Date:   Thu Apr 15 10:39:39 2010 +0200

* Fixed reserved word issue (fixes #370)

---

 .../models/Ext/ApplicationStateModel.class.php     |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/app/modules/AppKit/models/Ext/ApplicationStateModel.class.php b/app/modules/AppKit/models/Ext/ApplicationStateModel.class.php
index fccfeef..c025d17 100644
--- a/app/modules/AppKit/models/Ext/ApplicationStateModel.class.php
+++ b/app/modules/AppKit/models/Ext/ApplicationStateModel.class.php
@@ -3,7 +3,7 @@
 class AppKit_Ext_ApplicationStateModel extends ICINGAAppKitBaseModel implements AgaviISingletonModel
 {
 
-	const NAMESPACE = 'de.icinga.ext.appstate';
+	const PREFNS = 'de.icinga.ext.appstate';
 	
 	public function stateAvailable() {
 		if ($this->getContext()->getUser()->isAuthenticated()) {
@@ -16,7 +16,7 @@ class AppKit_Ext_ApplicationStateModel extends ICINGAAppKitBaseModel implements
 		$data = null;
 		
 		if ($this->stateAvailable()) {
-			$data = $this->getContext()->getUser()->getPrefVal(self::NAMESPACE, null, true);
+			$data = $this->getContext()->getUser()->getPrefVal(self::PREFNS, null, true);
 		}
 		
 		return $data;
@@ -26,7 +26,7 @@ class AppKit_Ext_ApplicationStateModel extends ICINGAAppKitBaseModel implements
 		if ($this->stateAvailable()) {
 			$existing = json_decode($this->readState());
 			$data = array_merge((is_array($existing)) ? $existing : array (), json_decode(($data)));
-			$this->getContext()->getUser()->setPref(self::NAMESPACE, json_encode($data), true, true);
+			$this->getContext()->getUser()->setPref(self::PREFNS, json_encode($data), true, true);
 		}
 	}
 	





More information about the icinga-checkins mailing list