From 32517c471ca63468fe33c20d46c74acb15fe0ab5 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Mon, 2 Dec 2013 09:41:53 +0100 Subject: [PATCH] Bug 11329: Check for marc record in catalogue/showmarc Intranet counterpart patch. Same check as in opac/opac-showmarc. Test plan: [1] Run showmarc.pl with valid biblionumber in id parameter. [2] Remove id parameter from URL. You should get a 404 now. Signed-off-by: Jonathan Druart --- catalogue/showmarc.pl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/catalogue/showmarc.pl b/catalogue/showmarc.pl index 0ee70c5..9cc039d 100755 --- a/catalogue/showmarc.pl +++ b/catalogue/showmarc.pl @@ -50,6 +50,10 @@ if ($importid) { else { $record =GetMarcBiblio($biblionumber); } +if(!ref $record) { + print $input->redirect("/cgi-bin/koha/errors/404.pl"); + exit; +} if($view eq 'card') { my $themelang = '/' . C4::Templates::_current_language(); -- 1.7.10.4