Bugzilla – Attachment 23231 Details for
Bug 11329
Check for marc record in opac-showmarc
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11329: Check for marc record in opac-showmarc
Bug-11329-Check-for-marc-record-in-opac-showmarc.patch (text/plain), 1.10 KB, created by
Marcel de Rooy
on 2013-12-02 08:40:13 UTC
(
hide
)
Description:
Bug 11329: Check for marc record in opac-showmarc
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2013-12-02 08:40:13 UTC
Size:
1.10 KB
patch
obsolete
>From 21771f5a262f61aebca55d05c01a644ae326960c Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Mon, 2 Dec 2013 09:30:13 +0100 >Subject: [PATCH] Bug 11329: Check for marc record in opac-showmarc >Content-Type: text/plain; charset=utf-8 > >Instead of just running as_formatted, check if GetMarcBiblio returned >a reference. If you e.g. did not pass an id, return 404 instead of 500. >Consistent with opac-export.pl > >Test plan: >[1] Run opac-showmarc.pl with valid biblionumber in id parameter. >[2] Remove id parameter from URL. You should get a 404 now. >--- > opac/opac-showmarc.pl | 4 ++++ > 1 files changed, 4 insertions(+), 0 deletions(-) > >diff --git a/opac/opac-showmarc.pl b/opac/opac-showmarc.pl >index 71fb804..27ab61c 100755 >--- a/opac/opac-showmarc.pl >+++ b/opac/opac-showmarc.pl >@@ -54,6 +54,10 @@ if ($importid) { > else { > $record =GetMarcBiblio($biblionumber); > } >+if(!ref $record) { >+ print $input->redirect("/cgi-bin/koha/errors/404.pl"); >+ exit; >+} > > if ($view eq 'card' || $view eq 'html') { > my $xmlrecord= $importid? $record->as_xml(): GetXmlBiblio($biblionumber); >-- >1.7.7.6
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 11329
:
23231
|
23232
|
24417
|
24418
|
24500
|
24501
|
24502