From 4d1a9240614b125abf00428fd41afda1f5d11395 Mon Sep 17 00:00:00 2001 From: erickson Date: Mon, 17 Nov 2008 15:06:20 +0000 Subject: [PATCH] handle non-existent bucket more gracefully git-svn-id: svn://svn.open-ils.org/ILS/branches/rel_1_4@11241 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/perlmods/OpenILS/WWW/Exporter.pm | 5 +++++ 1 file changed, 5 insertions(+) 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); -- 2.11.0