Sending e-mails and settings on Team.
This commit is contained in:
@@ -3,7 +3,6 @@
|
||||
namespace App\Notifications\Channels;
|
||||
|
||||
use App\Jobs\SendMessageToDiscordJob;
|
||||
use App\Models\InstanceSettings;
|
||||
use Illuminate\Notifications\Notification;
|
||||
|
||||
class DiscordChannel
|
||||
@@ -11,14 +10,11 @@ class DiscordChannel
|
||||
/**
|
||||
* Send the given notification.
|
||||
*/
|
||||
public function send(object $notifiable, Notification $notification): void
|
||||
public function send(SendsDiscord $notifiable, Notification $notification): void
|
||||
{
|
||||
$message = $notification->toDiscord($notifiable);
|
||||
|
||||
$webhookUrl = data_get(
|
||||
InstanceSettings::get(),
|
||||
'extra_attributes.discord_webhook'
|
||||
);
|
||||
$webhookUrl = $notifiable->routeNotificationForDiscord();
|
||||
|
||||
dispatch(new SendMessageToDiscordJob($message, $webhookUrl));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user