From: Michael M Slusarz Date: Fri, 22 Oct 2010 17:35:43 +0000 (-0600) Subject: Bug #9331: Only alter setting defaults if entry is in the same scope X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=ec81dfc2f3505205d2c8eb7ad95cadec64353036;p=horde.git Bug #9331: Only alter setting defaults if entry is in the same scope --- diff --git a/framework/Prefs/lib/Horde/Prefs.php b/framework/Prefs/lib/Horde/Prefs.php index 23da1ccab..a9220d58f 100644 --- a/framework/Prefs/lib/Horde/Prefs.php +++ b/framework/Prefs/lib/Horde/Prefs.php @@ -561,10 +561,11 @@ class Horde_Prefs implements ArrayAccess if (($prefs = $this->_storage->get($scope)) !== false) { foreach ($prefs as $name => $val) { - if ($this->isDefault($name)) { - $this->_scopes[$scope][$name]['d'] = $this->_scopes[$scope][$name]['v']; - - } elseif (!isset($this->_scopes[$scope][$name])) { + if (isset($this->_scopes[$scope][$name])) { + if ($this->isDefault($name)) { + $this->_scopes[$scope][$name]['d'] = $this->_scopes[$scope][$name]['v']; + } + } else { $this->_scopes[$scope][$name] = array( 'm' => 0 );