Skip to content

Commit

Permalink
Fix psalm issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Tigrov committed Jun 29, 2024
1 parent 3bbdddd commit fe8f61c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/QueryBuilder/Condition/AbstractOverlapsCondition.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,13 @@ public function getValues(): iterable|ExpressionInterface
*
* @throws InvalidArgumentException If the number of operands isn't 2.
*/
public static function fromArrayDefinition(string $operator, array $operands): self
public static function fromArrayDefinition(string $operator, array $operands): static
{
if (!isset($operands[0], $operands[1])) {
throw new InvalidArgumentException("Operator '$operator' requires three operands.");

Check warning on line 43 in src/QueryBuilder/Condition/AbstractOverlapsCondition.php

View check run for this annotation

Codecov / codecov/patch

src/QueryBuilder/Condition/AbstractOverlapsCondition.php#L43

Added line #L43 was not covered by tests
}

/** @psalm-suppress UnsafeInstantiation */
return new static(
self::validateColumn($operator, $operands[0]),
self::validateValues($operator, $operands[1])
Expand Down

0 comments on commit fe8f61c

Please sign in to comment.