/
githubmirror
/
symfony
Обзор
Документация
Войти
/
githubmirror
/
symfony
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
8.2
src/Symfony/Component/Notifier/FlashMessage/AbstractFlashMessageImportanceMapper.php
29 строк
791 B
Fabien Potencier
Add missing dep
26 мар 2022, 13:59
26 мар 2022, 13:59
1904fed
Код
Авторство
О чём код?
<?php /* * This file is part of the Symfony package. * * (c) Fabien Potencier <fabien@symfony.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Notifier\FlashMessage; use Symfony\Component\Notifier\Exception\FlashMessageImportanceMapperException; /** * @author Ben Roberts <ben@headsnet.com> */ abstract class AbstractFlashMessageImportanceMapper { public function flashMessageTypeFromImportance(string $importance): string { if (!\array_key_exists($importance, static::IMPORTANCE_MAP)) { throw new FlashMessageImportanceMapperException($importance, static::class); } return static::IMPORTANCE_MAP[$importance]; } }