Skip to content

Commit 8033d7b

Browse files
committed
[components][expression_language] Fix the wrong constructor for
SerializedParsedExpression There is a bug in the code snippet for creating a SerializedParsedExpression instance in chapter "Using Parsed and Serialized Expressions" | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | all | Fixed tickets |
1 parent 747696a commit 8033d7b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

components/expression_language/caching.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ Both ``evaluate()`` and ``compile()`` can handle ``ParsedExpression`` and
6565
6666
$expression = new SerializedParsedExpression(
6767
'1 + 4',
68-
serialize($language->parse('1 + 4', array()))
68+
serialize($language->parse('1 + 4', array())->getNodes())
6969
);
7070
7171
echo $language->evaluate($expression); // prints 5

0 commit comments

Comments
 (0)