Conditions | 3 |
Paths | 3 |
Total Lines | 14 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
28 | public function send($notifiable, Notification $notification) |
||
29 | { |
||
30 | $message = $notification->toHooks($notifiable); |
||
31 | |||
32 | if ($message->alertIdNotGiven()) { |
||
33 | if (!$alertId = $notifiable->routeNotificationFor('hooks')) { |
||
34 | throw CouldNotSendNotification::alertIdNotProvided(); |
||
35 | } |
||
36 | |||
37 | $message->alertId($alertId); |
||
38 | } |
||
39 | |||
40 | $this->hooks->send($message->toArray()); |
||
41 | } |
||
42 | } |
||
43 |