/**
  * Send the given notification.
  *
  * @param  mixed  $notifiable
  * @param  \Illuminate\Notifications\Notification  $notification
  * @return \Psr\Http\Message\ResponseInterface
  */
 public function send($notifiable, Notification $notification)
 {
     if (!($url = $notifiable->routeNotificationFor('slack'))) {
         return;
     }
     $message = $notification->toSlack($notifiable);
     return $this->http->post($url, ['json' => ['text' => $message->content, 'attachments' => $this->attachments($message)]]);
 }
 /**
  * Send the given notification.
  *
  * @param  mixed  $notifiable
  * @param  \Illuminate\Notifications\Notification  $notification
  * @return \Psr\Http\Message\ResponseInterface
  */
 public function send($notifiable, Notification $notification)
 {
     if (!($url = $notifiable->routeNotificationFor('slack'))) {
         return;
     }
     $message = $notification->toSlack($notifiable);
     $this->http->post($url, $this->buildJsonPayload($message));
 }