public function mapLogLevel(ErrorInterface $error)
    {

        // initialize the log level, default is 'error'
        $logLevel = LogLevel::ERROR;

        // query the error type
        switch ($error->getType()) {
            case E_WARNING:
            case E_USER_WARNING:
            case E_COMPILE_WARNING:
            case E_RECOVERABLE_ERROR:
                $logLevel = LogLevel::WARNING;
                break;

            case E_NOTICE:
            case E_USER_NOTICE:
            case E_STRICT:
            case E_DEPRECATED:
            case E_USER_DEPRECATED:
                $logLevel = LogLevel::NOTICE;
                break;

            default:
                break;
        }

        // return the log level
        return $logLevel;
    }