protected function detectGroupFromContentType()
    {
        if (extension_loaded('curl'))
        {
            $this->getLogger()->warning('Attempting to determine asset group using cURL. This may have a considerable effect on application speed.');

            $handler = curl_init($this->absolutePath);

            curl_setopt($handler, CURLOPT_RETURNTRANSFER, true);
            curl_setopt($handler, CURLOPT_FOLLOWLOCATION, true);
            curl_setopt($handler, CURLOPT_HEADER, true);
            curl_setopt($handler, CURLOPT_NOBODY, true);
            curl_setopt($handler, CURLOPT_SSL_VERIFYPEER, false);

            curl_exec($handler);

            if ( ! curl_errno($handler))
            {
                $contentType = curl_getinfo($handler, CURLINFO_CONTENT_TYPE);

                return starts_with($contentType, 'text/css') ? 'stylesheets' : 'javascripts';
            }
        }
    }