Skip to content

Commit 3f8f4a9

Browse files
committed
docs: move &$error description to numbered list
1 parent 403b473 commit 3f8f4a9

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

user_guide_src/source/libraries/validation.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -695,6 +695,7 @@ If your method needs to work with parameters, the function will need a minimum o
695695
1. the value to validate (``$value``)
696696
2. the parameter string (``$params``)
697697
3. an array with all of the data that was submitted the form (``$data``)
698+
4. (optional) a custom error string (``&$error``), just as described above.
698699

699700
.. warning:: The other field values in ``$data`` is unvalidated (or maybe invalid)
700701
data. Using unvalidated input data is a source of vulnerability. You must
@@ -706,8 +707,6 @@ for rules like ``required_with`` that needs to check the value of another submit
706707

707708
.. literalinclude:: validation/037.php
708709

709-
Custom errors can be returned as the fourth parameter ``&$error``, just as described above.
710-
711710
.. _validation-using-closure-rule:
712711

713712
Using Closure Rule

0 commit comments

Comments
 (0)