using bocontacts->default_addressbook for add_default; do not try to rebuild the logic of bo construct

This commit is contained in:
Klaus Leithoff 2010-12-13 13:20:20 +00:00
parent dfe7bcd02a
commit 0c4d7b8b47

View File

@ -466,7 +466,7 @@ switch($_POST['action'])
if (!isset($values['owner']) || isset($values['owner']) && (string)$values['owner'] === '') if (!isset($values['owner']) || isset($values['owner']) && (string)$values['owner'] === '')
{ {
// use default addressbook for new contacts (user preferences), if no owner specified // use default addressbook for new contacts (user preferences), if no owner specified
if(!($values['owner'] = $GLOBALS['egw_info']['user']['preferences']['addressbook']['add_default'])) if(!($values['owner'] = $bocontacts->default_addressbook))
{ {
$values['owner'] = $GLOBALS['egw_info']['user']['account_id']; $values['owner'] = $GLOBALS['egw_info']['user']['account_id'];
} }