Index: kernel/utility/unit_config_reader.php =================================================================== --- kernel/utility/unit_config_reader.php (revision 13962) +++ kernel/utility/unit_config_reader.php (working copy) @@ -441,7 +441,9 @@ $this->ParseConfigs(); $this->AfterConfigRead(false); $this->processDynamicClones(); - $this->retrieveCollections(); + + // don't call kUnitConfigReader::retrieveCollections since it + // will overwrite what we already have in kApplication class instance } /** Index: units/site_domains/site_domain_eh.php =================================================================== --- units/site_domains/site_domain_eh.php (revision 13936) +++ units/site_domains/site_domain_eh.php (working copy) @@ -17,18 +17,19 @@ class SiteDomainEventHandler extends kDBEventHandler { /** - * Allows to override standart permission mapping + * Permission check override * + * @param kEvent $event */ - function mapPermissions() + function CheckPermission(&$event) { - parent::mapPermissions(); + if ($event->Name == 'OnItemBuild') { + // check permission without using $event->getSection(), + // so first cache rebuild won't lead to "ldefault_Name" field being used + return true; + } - $permissions = Array ( - 'OnItemBuild' => Array ('self' => true), - ); - - $this->permMapping = array_merge($this->permMapping, $permissions); + return parent::CheckPermission($event); } /**