Index: trunk/core/units/phrases/phrases_event_handler.php =================================================================== diff -u -N -r3282 -r5431 --- trunk/core/units/phrases/phrases_event_handler.php (.../phrases_event_handler.php) (revision 3282) +++ trunk/core/units/phrases/phrases_event_handler.php (.../phrases_event_handler.php) (revision 5431) @@ -11,11 +11,9 @@ { parent::OnNew($event); $label = $this->Application->GetVar('phrases_label'); - $this->Application->setUnitOption($event->Prefix,'AutoLoad',false); - $object =& $event->getObject( $label ? Array('live_table'=>true) : Array() ); - if($label) - { + $object =& $event->getObject( $label ? Array('live_table'=>true, 'skip_autoload' => true) : Array('skip_autoload' => true) ); + if ($label) { $object->SetDBField('Phrase',$label); $object->SetDBField('LanguageId', $this->Application->GetVar('m_lang') ); $object->SetDBField('PhraseType',1); @@ -46,12 +44,9 @@ function OnBeforePhraseCreate(&$event) { $edit_direct = $this->Application->GetVar($event->Prefix.'_label'); - if($edit_direct) - { - $this->Application->setUnitOption($event->Prefix,'AutoLoad',false); - $object =& $event->getObject(); - if( $this->Application->GetVar('m_lang') != $this->Application->GetVar('lang_id') ) - { + if ($edit_direct) { + $object =& $event->getObject( Array('skip_autoload' => true) ); + if ($this->Application->GetVar('m_lang') != $this->Application->GetVar('lang_id')) { $object->SwitchToLive(); } }