Skip to content

Commit

Permalink
Fixed filtering rejections code
Browse files Browse the repository at this point in the history
  • Loading branch information
gplanchat committed Dec 11, 2024
1 parent 9694ef8 commit d631b9d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/Plugin/Filtering/Builder/Drop.php
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,9 @@ class: new Node\Name\FullyQualified(
),
args: [
new Node\Arg(
new Node\Scalar\String_($this->reason),
$this->reason !== null
? new Node\Scalar\String_($this->reason)
: new Node\Expr\ConstFetch(new Node\Name('null')),
),
new Node\Arg(
new Node\Expr\ConstFetch(new Node\Name('null')),
Expand Down
4 changes: 3 additions & 1 deletion src/Plugin/Filtering/Builder/Reject.php
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,9 @@ class: new Node\Name\FullyQualified(
),
args: [
new Node\Arg(
new Node\Scalar\String_($this->reason),
$this->reason !== null
? new Node\Scalar\String_($this->reason)
: new Node\Expr\ConstFetch(new Node\Name('null')),
),
new Node\Arg(
new Node\Expr\ConstFetch(new Node\Name('null')),
Expand Down

0 comments on commit d631b9d

Please sign in to comment.