From e57624affc1bb4f29408599044aa862aa1de9cc7 Mon Sep 17 00:00:00 2001 From: Xurshudyan Date: Tue, 23 Jul 2024 08:01:25 +0400 Subject: [PATCH] rename to for clarity --- validation.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/validation.md b/validation.md index 664ba79390c..c73f5079073 100644 --- a/validation.md +++ b/validation.md @@ -1934,7 +1934,7 @@ Alternatively, you may use the `exclude_unless` rule to not validate a given fie In some situations, you may wish to run validation checks against a field **only** if that field is present in the data being validated. To quickly accomplish this, add the `sometimes` rule to your rule list: - $v = Validator::make($data, [ + $validator = Validator::make($data, [ 'email' => 'sometimes|required|email', ]);