Skip to content
Snippets Groups Projects
Commit 49c20cac authored by Demian Katz's avatar Demian Katz
Browse files

Simplified HTTP access.

parent 416858ab
No related merge requests found
......@@ -27,8 +27,7 @@
*/
namespace VuFind\Controller;
use VuFind\Config\Reader as ConfigReader,
VuFind\Exception\Forbidden as ForbiddenException,
VuFind\Http\Client as HttpClient, Zend\Mvc\MvcEvent;
VuFind\Exception\Forbidden as ForbiddenException, Zend\Mvc\MvcEvent;
/**
* Class controls VuFind administration.
......@@ -131,8 +130,8 @@ class AdminController extends AbstractBase
$config = ConfigReader::getConfig();
$xml = false;
if (isset($config->Index->url)) {
$client = new HttpClient($config->Index->url . '/admin/multicore');
$response = $client->setMethod('GET')->send();
$response = $this->getServiceLocator()->get('VuFind\Http')
->get($config->Index->url . '/admin/multicore');
$xml = $response->isSuccess() ? $response->getBody() : false;
}
$view = $this->createViewModel();
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment