diff --git a/library/Class/WebService/SIGB/Koha/PatronInfoReader.php b/library/Class/WebService/SIGB/Koha/PatronInfoReader.php index 44bfeacaa7f7909a0c30b38041501e4c85f1a938..b3dd81dce1b7a3f491ad3249f468548d596e44b3 100644 --- a/library/Class/WebService/SIGB/Koha/PatronInfoReader.php +++ b/library/Class/WebService/SIGB/Koha/PatronInfoReader.php @@ -58,7 +58,8 @@ class Class_WebService_SIGB_Koha_PatronInfoReader extends Class_WebService_SIGB_ public function endHoldingbranch($data) { $data = trim($data); - if (!$data || !($site = Class_CodifAnnexe::findFirstBy(['code' => $data]))) + if (!$this->_currentLoan || !$data + || !($site = Class_CodifAnnexe::findFirstBy(['code' => $data]))) return; $this->_current_operation->getExemplaire()->setBibliotheque($site->getLibelle());