diff --git a/lib/private/tags.php b/lib/private/tags.php index e00c1b90ca..9ff433b698 100644 --- a/lib/private/tags.php +++ b/lib/private/tags.php @@ -227,10 +227,10 @@ class Tags implements \OCP\ITags { } $entry = $entries[$objId][] = $row['category']; } - } - if (\OCP\DB::isError($result)) { - \OCP\Util::writeLog('core', __METHOD__. 'DB error: ' . \OCP\DB::getErrorMessage($result), \OCP\Util::ERROR); - return false; + if (\OCP\DB::isError($result)) { + \OCP\Util::writeLog('core', __METHOD__. 'DB error: ' . \OCP\DB::getErrorMessage($result), \OCP\Util::ERROR); + return false; + } } } catch(\Exception $e) { \OCP\Util::writeLog('core', __METHOD__.', exception: '.$e->getMessage(),