diff --git a/src/palace/manager/api/sip/__init__.py b/src/palace/manager/api/sip/__init__.py index d76445e72..c3150ce7a 100644 --- a/src/palace/manager/api/sip/__init__.py +++ b/src/palace/manager/api/sip/__init__.py @@ -362,7 +362,8 @@ def _enforce_patron_location_restriction( the location associated with the patron exactly matches that of the library. """ if ( - self.patron_location_restriction is not None + not isinstance(info, ProblemDetail) + and self.patron_location_restriction is not None and info.get("permanent_location") != self.patron_location_restriction ): raise ProblemDetailException(PATRON_OF_ANOTHER_LIBRARY)