From e905106642efcbd2a02146a570bf6dfa5c2bed30 Mon Sep 17 00:00:00 2001 From: Nahuel ANGELINETTI Date: Tue, 16 Feb 2010 14:34:58 +0100 Subject: [PATCH] (bug #4195) fix OAI repository this fix the OAI repository, to don't return resumptionToken if there is no more record. Signed-off-by: Galen Charlton --- opac/oai.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/opac/oai.pl b/opac/oai.pl index 370f3e75d5..36c15e7faf 100755 --- a/opac/oai.pl +++ b/opac/oai.pl @@ -11,7 +11,7 @@ use C4::Context; BEGIN { eval { require PerlIO::gzip }; - $GZIP = $@ ? 0 : 1; + $GZIP = ($@) ? 0 : 1; } unless ( C4::Context->preference('OAI-PMH') ) { @@ -303,7 +303,7 @@ sub new { metadataPrefix => $token->{metadata_prefix}, from => $token->{from}, until => $token->{until}, - offset => $pos ) ); + offset => $pos ) ) if ($pos > $token->{offset}); return $self; } @@ -350,7 +350,7 @@ sub new { metadataPrefix => $token->{metadata_prefix}, from => $token->{from}, until => $token->{until}, - offset => $pos ) ); + offset => $pos ) ) if ($pos > $token->{offset}); return $self; } -- 2.39.5