1
0
mirror of https://github.com/owncloudarchive/contacts.git synced 2025-01-30 19:52:17 +01:00

Throw a more understable exception

This commit is contained in:
Thomas Tanghus 2013-12-28 10:02:22 +01:00
parent a13a319efb
commit b532adfaaa

View File

@ -99,7 +99,7 @@ class AddressBookController extends Controller {
$backend = $this->app->getBackend($params['backend']);
if(!$backend->hasAddressBookMethodFor(\OCP\PERMISSION_CREATE)) {
throw new \Exception('Not implemented');
throw new \Exception('This backend does not support adding address books', 501);
}
try {
$id = $backend->createAddressBook($this->request->post);