public function getFlashMessage($key)
    {
        $session = static::getInstance();
        foreach ($session->getFlashBag()->get($key, []) as $message) {
            return $message ?: null;
        }

        return '';
    }