Skip to content

Commit 0e34580

Browse files
intrepidwskorridor
authored andcommitted
Fix ignore method code example issue
This example didn't work for me - only adding in these parenthesis allowed it to work.
1 parent e4ba366 commit 0e34580

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ public function rules()
8181

8282
return [
8383
'id' => [new ExistsEloquent(Post::class)],
84-
'username' => [new UniqueEloquent(User::class, 'username')->ignore($postId)],
84+
'username' => [(new UniqueEloquent(User::class, 'username'))->ignore($postId)],
8585
'title' => ['string'],
8686
'content' => ['string'],
8787
'comments.*.id' => [

0 commit comments

Comments
 (0)