Skip to content

Commit

Permalink
OXDEV-8724 Resolve phpstan warning
Browse files Browse the repository at this point in the history
  • Loading branch information
RahatHameed committed Sep 23, 2024
1 parent 1611bfd commit a8ca830
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/UserData/Infrastructure/UserDataRepository.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

namespace OxidEsales\GdprOptinModule\UserData\Infrastructure;

use Doctrine\DBAL\ForwardCompatibility\Result;
use OxidEsales\EshopCommunity\Internal\Framework\Database\QueryBuilderFactoryInterface;

class UserDataRepository implements UserDataRepositoryInterface
Expand All @@ -26,7 +27,10 @@ public function getDataFromTable(string $table, string $columnName, string $colu
->where($columnName . ' = :' . $columnName)
->setParameter($columnName, $columnValue);

return $queryBuilder->execute()->fetchAllAssociative();
/** @var Result $result */
$result = $queryBuilder->execute();

return $result->fetchAllAssociative();
}

public function getJoinedData(
Expand All @@ -44,6 +48,9 @@ public function getJoinedData(
->where($primaryTable . '.' . $primaryColumn . ' = :' . $primaryColumn)
->setParameter($primaryColumn, $primaryValue);

return $queryBuilder->execute()->fetchAllAssociative();
/** @var Result $result */
$result = $queryBuilder->execute();

return $result->fetchAllAssociative();
}
}

0 comments on commit a8ca830

Please sign in to comment.