Browse Source

fix bug with ambiguous sql call

Olivier Massot 4 years ago
parent
commit
7a55404d6d
1 changed files with 1 additions and 1 deletions
  1. 1 1
      ot_core/Classes/Website/OtWebsiteRepository.php

+ 1 - 1
ot_core/Classes/Website/OtWebsiteRepository.php

@@ -187,7 +187,7 @@ class OtWebsiteRepository
             ->where($queryBuilder->expr()->eq('w.organization_id', $organizationId))
             ->where($queryBuilder->expr()->eq('w.organization_id', $organizationId))
             ->andWhere($queryBuilder->expr()->eq('p.is_siteroot', 1));
             ->andWhere($queryBuilder->expr()->eq('p.is_siteroot', 1));
         if ($withRestrictions) {
         if ($withRestrictions) {
-            $q->andWhere($q->expr()->eq('deleted', 0));
+            $q->andWhere($q->expr()->eq('w.deleted', 0));
         }
         }
         $rootUid = $q->execute()->fetchColumn(0);
         $rootUid = $q->execute()->fetchColumn(0);
         if (!$rootUid) {
         if (!$rootUid) {