protected function generateVaryHeader(HTTPResponse $response)
    {
        // split the current vary header into it's parts and merge it with the config settings
        // to create a list of unique vary values
        $vary = $this->getVary();
        if ($response->getHeader('Vary')) {
            $vary = $this->combineVary($vary, $response->getHeader('Vary'));
        }
        if ($vary) {
            return implode(', ', $vary);
        }
        return null;
    }