X-Git-Url: http://git.equinoxoli.org/?p=migration-tools.git;a=blobdiff_plain;f=marc_cleanup;h=e0c20a781afd6f13c10402f017df98f913e9e8cf;hp=c26525cc3794013ef8eeadd6b09373b7364985a9;hb=1a3ca3ba98d644892f5fbad6084e515736394452;hpb=c427e4db4bbe3c6dc11bb8e5739a964fee6ac381 diff --git a/marc_cleanup b/marc_cleanup index c26525c..e0c20a7 100755 --- a/marc_cleanup +++ b/marc_cleanup @@ -193,6 +193,12 @@ sub do_automated_cleanups { message("Dollar sign corrected"); } + # excessive trailing whitespace in subfield contents + if ($record[$ptr] =~ m|\s{10,}|) { + $record[$ptr] =~ s|\s{10,}||; + message("Trailing whitespace trimmed from subfield contents"); + } + # automatable subfield maladies $record[$ptr] =~ s/code=" ">c/code="c">/; $record[$ptr] =~ s/code=" ">\$/code="c">\$/;