@@ -, +, @@ --- C4/Ris.pm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) --- a/C4/Ris.pm +++ a/C4/Ris.pm @@ -65,6 +65,7 @@ package C4::Ris; use List::MoreUtils qw/uniq/; use vars qw($VERSION @ISA @EXPORT); + # set the version for version checking $VERSION = 3.07.00.049; @@ -87,12 +88,14 @@ C<$record> - a MARC::Record object =cut +my $intype; + sub marc2ris { my ($record) = @_; my $output; my $marcflavour = C4::Context->preference("marcflavour"); - my $intype = lc($marcflavour); + $intype = lc($marcflavour); my $marcprint = 0; # Debug flag; # Let's redirect stdout @@ -409,7 +412,7 @@ sub normalize_author { ## we currently ignore subfield c until someone complains if (length($rawauthorb) > 0) { - return join ",", ($rawauthora, $rawauthorb); + return join ", ", ($rawauthora, $rawauthorb); } else { return $rawauthora; @@ -448,7 +451,7 @@ sub get_author { normalize_author($authorname, $authorfield->subfield('b'), $authorfield->subfield('c'), $authorfield->indicator("$indicator")); } else { - normalize_author($authorfield->subfield('a'), $authorfield->subfield('b'), $authorfield->subfield('c'), $authorfield->indicator("$indicator")); + normalize_author($authorfield->subfield('a') // '', $authorfield->subfield('b') // '', $authorfield->subfield('c') // '', $authorfield->indicator("$indicator")); } } --