From: erickson Date: Mon, 17 Nov 2008 15:05:55 +0000 (+0000) Subject: handle non-existent bucket more gracefully X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=90d3a320973d504e037a52a1f56955319550b90a;p=Evergreen.git handle non-existent bucket more gracefully git-svn-id: svn://svn.open-ils.org/ILS/trunk@11240 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/WWW/Exporter.pm b/Open-ILS/src/perlmods/OpenILS/WWW/Exporter.pm index 7f3621510e..6de6e1461c 100644 --- a/Open-ILS/src/perlmods/OpenILS/WWW/Exporter.pm +++ b/Open-ILS/src/perlmods/OpenILS/WWW/Exporter.pm @@ -88,6 +88,11 @@ sub handler { my $container = $cgi->param('containerid'); if ($container) { my $bucket = $ses->request( 'open-ils.cstore.direct.container.biblio_record_entry_bucket.retrieve', $container )->gather(1); + unless($bucket) { + $r->log->error("No such bucket $container"); + $logger->error("No such bucket $container"); + return Apache2::Const::NOT_FOUND; + } if ($bucket->pub !~ /t|1/oi) { my $authid = $cgi->cookie('ses') || $cgi->param('ses'); my $auth = verify_login($authid);