File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -45,20 +45,16 @@ public function toDatabase($notifiable): array
4545 $ body = $ this ->getBody ();
4646 $ icon = $ this ->status === 'success ' ? 'heroicon-o-check-circle ' : 'heroicon-o-x-circle ' ;
4747 $ iconColor = $ this ->status === 'success ' ? 'success ' : 'danger ' ;
48-
49- FilamentNotification::make ()
50- ->title ($ title )
51- ->body ($ body )
52- ->icon ($ icon )
53- ->iconColor ($ iconColor )
54- ->broadcast ($ notifiable );
55-
56- return FilamentNotification::make ()
48+
49+ $ notification = FilamentNotification::make ()
5750 ->title ($ title )
5851 ->body ($ body )
5952 ->icon ($ icon )
60- ->iconColor ($ iconColor )
61- ->getDatabaseMessage ();
53+ ->iconColor ($ iconColor );
54+
55+ $ notification ->broadcast ($ notifiable );
56+
57+ return $ notification ->getDatabaseMessage ();
6258 }
6359
6460 public function toArray (): array
You can’t perform that action at this time.
0 commit comments