mirror of
https://github.com/AnimeThemes/animethemes-server.git
synced 2026-09-05 04:05:07 +02:00
31 lines
664 B
PHP
31 lines
664 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Events\Admin\Feature;
|
|
|
|
use App\Events\Base\Admin\AdminUpdatedEvent;
|
|
use App\Models\Admin\Feature;
|
|
|
|
/**
|
|
* @extends AdminUpdatedEvent<Feature>
|
|
*/
|
|
class FeatureUpdated extends AdminUpdatedEvent
|
|
{
|
|
public function __construct(Feature $feature)
|
|
{
|
|
parent::__construct($feature);
|
|
$this->initializeEmbedFields($feature);
|
|
}
|
|
|
|
protected function getDiscordMessageDescription(): string
|
|
{
|
|
return "Feature '**{$this->getModel()->getName()}**' has been updated.";
|
|
}
|
|
|
|
public function shouldSendDiscordMessage(): bool
|
|
{
|
|
return $this->getModel()->isNullScope();
|
|
}
|
|
}
|