I have this configuration where the user can set which notification it wants to receive, I don't want to do an If on every method that I call notify.
I'd like to know if is there a method inside my notification class that I can do this validation, or how could I do that.
I thought about a solution, but it seens durty, I could validate inside via and just return an empty array if the user setted to not receive
And I also find out a method inside Illuminate\Notifications\NotificationSender called shouldSendNotification but I don't know how I could overwrite it, or even if it is using this class, cause it seens to be only for queue
OBS: Laravel 7