Skip to content
Snippets Groups Projects
Commit 8bcc1ba8 authored by Demian Katz's avatar Demian Katz Committed by Robert Lange
Browse files

Apply is_holdable setting more consistently.

parent b5e69893
No related merge requests found
...@@ -281,7 +281,8 @@ class Holds ...@@ -281,7 +281,8 @@ class Holds
if ($holdConfig) { if ($holdConfig) {
// Is this copy holdable / linkable // Is this copy holdable / linkable
if (!$requestsBlocked if (!$requestsBlocked
&& isset($copy['addLink']) && $copy['addLink'] && ($copy['addLink'] ?? false)
&& ($copy['is_holdable'] ?? true)
) { ) {
$copy['link'] = $this->getRequestDetails( $copy['link'] = $this->getRequestDetails(
$copy, $holdConfig['HMACKeys'], 'Hold' $copy, $holdConfig['HMACKeys'], 'Hold'
...@@ -363,10 +364,7 @@ class Holds ...@@ -363,10 +364,7 @@ class Holds
} }
// If a valid holdable status has been set, use it to // If a valid holdable status has been set, use it to
// determine if a hold link is created // determine if a hold link is created
$addlink = isset($copy['is_holdable']) if ($addlink && ($copy['is_holdable'] ?? true)) {
? ($addlink && $copy['is_holdable']) : $addlink;
if ($addlink) {
if ($holdConfig['function'] == "getHoldLink") { if ($holdConfig['function'] == "getHoldLink") {
/* Build opac link */ /* Build opac link */
$holdings[$location_key][$copy_key]['link'] $holdings[$location_key][$copy_key]['link']
......
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