diff options
author | Thomas Tanghus <thomas@tanghus.net> | 2012-04-12 20:16:56 +0200 |
---|---|---|
committer | Thomas Tanghus <thomas@tanghus.net> | 2012-04-13 18:50:40 +0200 |
commit | b654121b502e7c823f8a135a2c6a0f6edb176a8e (patch) | |
tree | b497fe344efbb01f7313be52a88c2987b0d9a274 /apps | |
parent | 6066ea31705c9c2b852350edd80e2f9a2c27124b (diff) | |
download | nextcloud-server-b654121b502e7c823f8a135a2c6a0f6edb176a8e.tar.gz nextcloud-server-b654121b502e7c823f8a135a2c6a0f6edb176a8e.zip |
Contacts: Better error reporting.
Diffstat (limited to 'apps')
-rw-r--r-- | apps/contacts/lib/app.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/contacts/lib/app.php b/apps/contacts/lib/app.php index f6f6e619075..211e459e56f 100644 --- a/apps/contacts/lib/app.php +++ b/apps/contacts/lib/app.php @@ -53,11 +53,12 @@ class OC_Contacts_App { if( $addressbook === false || $addressbook['userid'] != OC_User::getUser()) { if ($addressbook === false) { OC_Log::write('contacts', 'Addressbook not found: '. $id, OC_Log::ERROR); + OC_JSON::error(array('data' => array( 'message' => self::$l10n->t('Addressbook not found.')))); } else { OC_Log::write('contacts', 'Addressbook('.$id.') is not from '.OC_User::getUser(), OC_Log::ERROR); + OC_JSON::error(array('data' => array( 'message' => self::$l10n->t('This is not your addressbook.')))); } - OC_JSON::error(array('data' => array( 'message' => self::$l10n->t('This is not your addressbook.')))); // Same here (as with the contact error). Could this error be improved? exit(); } return $addressbook; |