Index: trunk/kernel/include/usersession.php =================================================================== diff -u -N -r7413 -r7884 --- trunk/kernel/include/usersession.php (.../usersession.php) (revision 7413) +++ trunk/kernel/include/usersession.php (.../usersession.php) (revision 7884) @@ -638,22 +638,22 @@ { global $objConfig, $objUsers; + $val = ''; $UserID = $this->Get("PortalUserId"); - if(is_numeric($UserID)) - { - if(!is_object($this->CurrentUser)) - { + if (is_numeric($UserID)) { + if (!is_object($this->CurrentUser)) { $this->CurrentUser = $objUsers->GetItem($UserID); } - if(!$this->CurrentUser->VarsLoaded) - { + if (!$this->CurrentUser->VarsLoaded) { $this->CurrentUser->LoadPersistantVars(); } $val = $this->CurrentUser->GetPersistantVariable($variableName); //echo "Persistant Val for $variableName: $val
"; } - if(!strlen($val)) + if (!strlen($val)) { $val = $objConfig->Get($variableName); + } + return $val; } Index: trunk/core/units/categories/cache_updater.php =================================================================== diff -u -N -r7855 -r7884 --- trunk/core/units/categories/cache_updater.php (.../cache_updater.php) (revision 7855) +++ trunk/core/units/categories/cache_updater.php (.../cache_updater.php) (revision 7884) @@ -105,25 +105,13 @@ function GetInsertSQL() { $values = array(); - - $has_deny = array(); - - // don't write DACL at all - /*foreach ($this->Deny as $perm => $groups) { - if (count($groups) > 0) { - $values[] = '('.$this->CatId.', '.$perm.', "", "'.join(',', $groups).'")'; - $has_deny[] = $perm; - } - }*/ - foreach ($this->Allow as $perm => $groups) { -// if (in_array($perm, $has_deny)) continue; if (count($groups) > 0) { - $values[] = '(' .$this->CatId. ', ' .$perm. ', "' .join(',', $groups). '", "")'; + $values[] = '(' .$this->CatId. ', ' .$perm. ', "' .join(',', $groups). '")'; } } if (!$values) return ''; - $sql = 'INSERT INTO '.TABLE_PREFIX.'PermCache (CategoryId, PermId, ACL, DACL) VALUES '.join(',', $values); + $sql = 'INSERT INTO '.TABLE_PREFIX.'PermCache (CategoryId, PermId, ACL) VALUES '.join(',', $values); return $sql; } }