From aace784cf16419891e2b017e6b9e820cf386922e Mon Sep 17 00:00:00 2001 From: Jaswinder Singh Date: Mon, 17 Sep 2018 13:26:52 -0400 Subject: [PATCH] LP#1772680: Changed the code to accommodate new Registration Response Structure Signed-off-by: Jaswinder Singh Signed-off-by: Galen Charlton --- .../src/perlmods/lib/OpenILS/Application/EbookAPI/RBDigital.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/EbookAPI/RBDigital.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/EbookAPI/RBDigital.pm index ac960027fe..e56a6739d6 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/EbookAPI/RBDigital.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/EbookAPI/RBDigital.pm @@ -420,12 +420,12 @@ sub register_patron { $logger->info("EbookAPI: Calling an API to registering Patron: $username"); my $res = $self->request($req, $session_id); - if (defined ($res)) { - if ($res->{content}->{patronId}) { + if (defined($res)) { + if ($res->{content}->{patron}->{patronId}) { $logger->info("EbookAPI: User $username successfully registered with RBDigital portal."); - return $res->{content}->{patronId}; + return $res->{content}->{patron}->{patronId}; } else { - $logger->error("EbookAPI: Registration for $username to RBDigital failed: ".$res->{content}->{message}); + $logger->error("EbookAPI: Registration for $username to RBDigital failed: " . Dumper($res)); } } -- 2.11.0