Repair a thinko in create_lineitem_list_assets which resulted in each
lineitem havings its asset creation routine run twice. In addition to
making the code more efficient, this will avoid the unintended creation
of duplicate holds from ACQ user requests.
Note that copies and call numbers were not duplicated, because the code
was already preventing that.
Signed-off-by: Bill Erickson <berick@esilibrary.com>
);
# add the already-imported records to the response list
- push(@{$res->{li_ids}}, grep { $_ != @$needs_importing } @$li_ids);
+ for my $id (@$li_ids) {
+ push(@{$res->{li_ids}}, $id)
+ unless grep { $_ == $id } @$needs_importing;
+ }
$logger->info("acq-vl: processing recs via Vandelay with args: ".Dumper($vandelay));