Open sts-ryan-holton opened 2 years ago
You can send the $user to the notification class as a parameter of the __construct() method. In inside, you can save it like $this->user = $user. Then you can use it toTwitter() method.
That was the answer to "how to reach $user in the notification class" above. But with the routeNotificationForTwitter() method you don't need anything. The method does it by itself.
I have a
routeNotificationForTwitter
on myUser
model which returns the Twitter username for my user, how can I access this within my notification'stoTwitter
method?