From: erickson Date: Fri, 17 Sep 2010 17:11:03 +0000 (+0000) Subject: back-port: 17765 => protect against fetching lineitem details by ref instead of ID X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=941e14c172b10cdf8ee511c6a51faa8742e53682;p=evergreen%2Fequinox.git back-port: 17765 => protect against fetching lineitem details by ref instead of ID git-svn-id: svn://svn.open-ils.org/ILS/branches/rel_2_0@17766 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Acq/Order.pm b/Open-ILS/src/perlmods/OpenILS/Application/Acq/Order.pm index 2318e2247e..6517646ce2 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Acq/Order.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Acq/Order.pm @@ -658,7 +658,9 @@ sub create_lineitem_detail_debit { ]); } - unless(ref $lid and ref $lid->fund) { + if(ref $lid) { + $lid->fund($mgr->editor->retrieve_acq_fund($lid->fund)) unless(ref $lid->fund); + } else { $lid = $mgr->editor->retrieve_acq_lineitem_detail([ $lid, { flesh => 1,