diff options
-rw-r--r-- | program/steps/addressbook/save.inc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/program/steps/addressbook/save.inc b/program/steps/addressbook/save.inc index 03f6671e6..e93ce9918 100644 --- a/program/steps/addressbook/save.inc +++ b/program/steps/addressbook/save.inc @@ -81,8 +81,8 @@ if (empty($a_record['name'])) { // do input checks (delegated to $CONTACTS instance) if (!$CONTACTS->validate($a_record)) { - $err = (array)$CONTACTS->get_error() + array('message' => 'formincomplete', 'type' => 'warning'); - $OUTPUT->show_message($err['message'], $err['type']); + $err = (array)$CONTACTS->get_error(); + $OUTPUT->show_message($err['message'] ? $err['message'] : 'formincomplete', 'warning'); $GLOBALS['EDIT_RECORD'] = $a_record; // store submitted data to be used in edit form rcmail_overwrite_action($return_action); return; |