Lines 100.00% 8 / 8
Methods 100.00% 5 / 5
Classes 100.00% 1 / 1
Name Lines Methods CRAP
 channel 100.00% 1 / 1 100.00% 1 / 1 1
 phrase 100.00% 1 / 1 100.00% 1 / 1 1
 summary 100.00% 1 / 1 100.00% 1 / 1 1
 [Lorekeeper\Server\Event\NoticeEvent] __construct 100.00% 1 / 1 100.00% 1 / 1 1
 [Lorekeeper\Server\Event\NoticeEvent] from 100.00% 4 / 4 100.00% 1 / 1 1
13final readonly class MapRequiresQuestEvent extends NoticeEvent
14{
15    #[Override]
16    protected static function channel(): string
17    {
18        return 'warning';
19    }
20
21    #[Override]
22    protected static function phrase(): string
23    {
24        return 'that map requires special quest actions';
25    }
26
27    #[Override]
28    public function summary(): string
29    {
30        return 'That map requires special quest actions';
31    }
32}

Inherited from Lorekeeper\Server\Event\NoticeEvent

15    final public function __construct() {}
23    final public static function from(Message $message): Option\Option
24    {
25        return Notice::text($message, static::channel())->filter(static fn(string $text): bool => str_contains(
26            strtolower($text),
27            static::phrase(),
28        ))->map(static fn(): static => new static());
29    }