Skip to content

Commit

Permalink
Rename connection and ini file to 'external'
Browse files Browse the repository at this point in the history
  • Loading branch information
maccabeelevine committed Dec 22, 2023
1 parent 74add46 commit 16df412
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 12 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
; This file configures the ConsortialVuFind recommendation module, which searches
; a separate instance of VuFind via its public API and links to the record and
; results pages hosted within that instance. This is intended to search and link
; to a consortial catalog, such as ReShare, which uses its own VuFind instance to
; This file configures the the ExternalVuFind connection service, which
; searches a separate instance of VuFind via its public API.

; That connection is used by the ConsortialVuFind recommendation module,
; which searches and links to a consortial catalog such as ReShare, to
; display consortium holdings and facilitate borrowing between institutions.

; The section name is specified in the recommendation module config.
Expand Down
2 changes: 1 addition & 1 deletion module/VuFind/config/module.config.php
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@
'VuFind\Config\PluginManager' => 'VuFind\Config\PluginManagerFactory',
'VuFind\Config\SearchSpecsReader' => 'VuFind\Config\YamlReaderFactory',
'VuFind\Config\YamlReader' => 'VuFind\Config\YamlReaderFactory',
'VuFind\Connection\ConsortialVuFind' => 'Laminas\ServiceManager\Factory\InvokableFactory',
'VuFind\Connection\ExternalVuFind' => 'Laminas\ServiceManager\Factory\InvokableFactory',
'VuFind\Connection\LibGuides' => 'VuFind\Connection\LibGuidesFactory',
'VuFind\Connection\Relais' => 'VuFind\Connection\RelaisFactory',
'VuFind\Content\PageLocator' => 'VuFind\Content\PageLocatorFactory',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php

/**
* Consortial VuFind API connection class.
* External VuFind API connection class.
*
* PHP version 8
*
Expand Down Expand Up @@ -33,15 +33,15 @@
use Laminas\Log\LoggerAwareInterface;

/**
* Consortial VuFind API connection class.
* External VuFind API connection class.
*
* @category VuFind
* @package Connection
* @author Maccabee Levine <[email protected]>
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License
* @link https://vufind.org
*/
class ConsortialVuFind implements
class ExternalVuFind implements
\VuFindHttp\HttpServiceAwareInterface,
LoggerAwareInterface
{
Expand Down Expand Up @@ -104,7 +104,7 @@ public function search($queryString, $requestParam, $limit, $searchFilters = [])

if ($response->isServerError()) {
$this->logError(
'ConsortialVuFind API HTTP Error: ' .
'ExternalVuFind API HTTP Error: ' .
$response->getStatusCode()
);
return [];
Expand Down
2 changes: 1 addition & 1 deletion module/VuFind/src/VuFind/Recommend/ConsortialVuFind.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
namespace VuFind\Recommend;

use Laminas\Config\Config;
use VuFind\Connection\ConsortialVuFind as Connection;
use VuFind\Connection\ExternalVuFind as Connection;

use function intval;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ public function __invoke(
}

return new $requestedName(
$container->get(\VuFind\Config\PluginManager::class)->get('ConsortialVuFind'),
$container->get(\VuFind\Connection\ConsortialVuFind::class)
$container->get(\VuFind\Config\PluginManager::class)->get('ExternalVuFind'),
$container->get(\VuFind\Connection\ExternalVuFind::class)
);
}
}

0 comments on commit 16df412

Please sign in to comment.