diff --git a/lib/Db/CoreRequestBuilder.php b/lib/Db/CoreRequestBuilder.php index cbb1031a..1aa5a5c3 100644 --- a/lib/Db/CoreRequestBuilder.php +++ b/lib/Db/CoreRequestBuilder.php @@ -1201,10 +1201,11 @@ class CoreRequestBuilder { */ public function emptyAll() { foreach ($this->tables as $table) { - $qb = $this->dbConnection->getQueryBuilder(); - $qb->delete($table); - - $qb->execute(); + if ($schema->hasTable($table)) { + $qb = $this->dbConnection->getQueryBuilder(); + $qb->delete($table); + $qb->execute(); + } } }