diff --git a/lib/Db/CacheActorsRequest.php b/lib/Db/CacheActorsRequest.php index ee54c7d2..4abfe820 100644 --- a/lib/Db/CacheActorsRequest.php +++ b/lib/Db/CacheActorsRequest.php @@ -242,7 +242,7 @@ class CacheActorsRequest extends CacheActorsRequestBuilder { $cursor->closeCursor(); if ($data === false) { - throw new CacheActorDoesNotExistException(); + throw new CacheActorDoesNotExistException('Unknown account \'' . $account . "'"); } return $this->parseCacheActorsSelectSql($data); diff --git a/lib/webfinger.php b/lib/webfinger.php index f4f1f426..2cf5a78a 100644 --- a/lib/webfinger.php +++ b/lib/webfinger.php @@ -54,17 +54,17 @@ if ($type !== 'acct') { list($username, $instance) = explode('@', $account); - try { $cacheActorService = OC::$server->query(CacheActorService::class); $configService = OC::$server->query(ConfigService::class); if ($configService->getCloudAddress(true) !== $instance) { - throw new Exception(); + throw new Exception('instance is ' . $instance . ', expected ' . $configService->getCloudAddress(true)); } $cacheActorService->getFromLocalAccount($username); } catch (Exception $e) { + OC::$server->getLogger()->log(1, 'Exception on webfinger - ' . $e->getMessage()); http_response_code(404); exit; }