You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can also pass second argument as $user in helper function `givePoint(new PostCreated($post, $user))`, default is auth()->user().
139
+
You can also pass second argument as $user in helper function `givePoint(new PostCreated($post), $user)`, default is auth()->user().
140
140
141
141
**Pro Tip 👌** You could also hook into the Eloquent model event and give point on `created` event. Similarly, `deleted` event can be used to undo the point.
0 commit comments