File tree 3 files changed +7
-7
lines changed
3 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ final class Reject implements StepBuilderInterface
16
16
private ?Node \Expr $ logger = null ;
17
17
private ?Node \Expr $ rejection = null ;
18
18
private ?Node \Expr $ state = null ;
19
- private ?Node \Expr $ dataToFormat = null ;
19
+ private ?Node \Expr $ serialize_rejection = null ;
20
20
/** @var list<?Node\Expr> */
21
21
private array $ exclusions = [];
22
22
@@ -43,9 +43,9 @@ public function withState(Node\Expr $state): self
43
43
return $ this ;
44
44
}
45
45
46
- public function withDataToFormat (Node \Expr $ dataToFormat ): self
46
+ public function withSerialiazeRejection (Node \Expr $ serialize_rejection ): self
47
47
{
48
- $ this ->dataToFormat = $ dataToFormat ;
48
+ $ this ->serialize_rejection = $ serialize_rejection ;
49
49
50
50
return $ this ;
51
51
}
@@ -133,7 +133,7 @@ class: new Node\Stmt\Class_(null, [
133
133
new Node \Expr \New_ (
134
134
new Node \Name \FullyQualified (RejectionResultBucket::class),
135
135
[
136
- $ this ->dataToFormat !== null ? new Node \Arg ($ this ->dataToFormat ) : new Node \Arg (new Node \Expr \Variable ('input ' ))
136
+ $ this ->serialize_rejection !== null ? new Node \Arg ($ this ->serialize_rejection ) : new Node \Arg (new Node \Expr \Variable ('input ' ))
137
137
]
138
138
),
139
139
),
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ public function getConfigTreeBuilder(): TreeBuilder
28
28
->then (asExpression ())
29
29
->end ()
30
30
->end ()
31
- ->scalarNode ('dataToFormat ' )
31
+ ->scalarNode ('serialize_rejection ' )
32
32
->cannotBeEmpty ()
33
33
->validate ()
34
34
->ifTrue (isExpression ())
Original file line number Diff line number Diff line change @@ -71,8 +71,8 @@ public function compile(array $config): Repository\Reject
71
71
$ builder ->withExclusions (
72
72
compileExpression ($ interpreter , $ condition ['when ' ])
73
73
);
74
- if (array_key_exists ('dataToFormat ' , $ condition )) {
75
- $ builder ->withDataToFormat (compileExpression ($ interpreter , $ condition ['dataToFormat ' ]));
74
+ if (array_key_exists ('serialize_rejection ' , $ condition )) {
75
+ $ builder ->withSerialiazeRejection (compileExpression ($ interpreter , $ condition ['serialize_rejection ' ]));
76
76
}
77
77
}
78
78
You can’t perform that action at this time.
0 commit comments