public function protocol($raw = false)
    {
        if ($raw) {
            return $this->server('SERVER_PROTOCOL');
        }

        $parts = explode('/', $this->server('SERVER_PROTOCOL'));

        return strtolower(array_shift($parts)) . $this->server('HTTPS') === 'on' ? 's' : '';
    }