Bugzilla – Attachment 42135 Details for
Bug 14363
OAI-PMH should handle records without marcxml
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14363: OAI-PMH: Handle records without marcxml
Bug-14363-OAI-PMH-Handle-records-without-marcxml.patch (text/plain), 873 bytes, created by
Julian Maurice
on 2015-09-01 07:48:31 UTC
(
hide
)
Description:
Bug 14363: OAI-PMH: Handle records without marcxml
Filename:
MIME Type:
Creator:
Julian Maurice
Created:
2015-09-01 07:48:31 UTC
Size:
873 bytes
patch
obsolete
>From a251e9dda7fbe1137c5d66e57c1cfe94118941ff Mon Sep 17 00:00:00 2001 >From: Julian Maurice <julian.maurice@biblibre.com> >Date: Tue, 1 Sep 2015 09:46:35 +0200 >Subject: [PATCH] Bug 14363: OAI-PMH: Handle records without marcxml > >--- > opac/oai.pl | 10 +++++++++- > 1 file changed, 9 insertions(+), 1 deletion(-) > >diff --git a/opac/oai.pl b/opac/oai.pl >index c4f4e8b..2bad067 100755 >--- a/opac/oai.pl >+++ b/opac/oai.pl >@@ -225,7 +225,15 @@ sub new { > } > > my $parser = XML::LibXML->new(); >- my $record_dom = $parser->parse_string( $marcxml ); >+ my $record_dom; >+ eval { >+ $record_dom = $parser->parse_string( $marcxml ); >+ }; >+ if ($@) { >+ warn "OAI-PMH: No marcxml for record " . $args{identifier}; >+ return $self; >+ } >+ > my $format = $args{metadataPrefix}; > if ( $format ne 'marcxml' ) { > my %args = ( >-- >1.9.1
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 14363
:
42135
|
45489
|
45499