Skip to content

Commit 7098dcc

Browse files
committed
Clarify the usage of the value variable in the When constraint documentation
1 parent 0daa9fa commit 7098dcc

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

reference/constraints/When.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,9 @@ in your expression:
173173
``this``
174174
The object being validated (e.g. an instance of Discount).
175175
``value``
176-
The value of the property being validated (only available when
177-
the constraint is applied to a property).
176+
Either the object being validated (when the constraint is applied to a class),
177+
the value of the property being validated (when applied to a property),
178+
or the :doc:`raw value </validation/raw_values>`.
178179

179180
The ``value`` variable can be used when you want to execute more complex
180181
validation based on its value:

0 commit comments

Comments
 (0)