Skip to content

Commit

Permalink
Improvements for php7
Browse files Browse the repository at this point in the history
  • Loading branch information
tychokamphuis-aqqo committed Aug 30, 2024
1 parent 72095df commit 9d92e69
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Drivers/SQL/SQLExpression.php
Original file line number Diff line number Diff line change
Expand Up @@ -1319,10 +1319,10 @@ protected function lambdaExpression(Lambda $node): void

$field = $this->entitySet->propertyToExpression($constraint->getProperty());

$relation = $constraint?->relation;
$relation = $constraint->getRelation();
if (isset($relation) && $relation instanceof HasManyThrough) {
$constraint->relation->select($relation->getQualifiedFirstKeyName());
$where = preg_replace('/\s+where\s+.*$/i', '', $constraint->relation->toSql());
$constraint->getRelation()->select($relation->getQualifiedFirstKeyName());
$where = preg_replace('/\s+where\s+.*$/i', '', $constraint->getRelation()->toSql());
$this->pushStatement(
sprintf('( %s = %s ( %s WHERE',
$field->getStatement(),
Expand Down

0 comments on commit 9d92e69

Please sign in to comment.