From 74446c6ee370f0b75424624df93cfc2010245ff1 Mon Sep 17 00:00:00 2001 From: Joe Date: Fri, 15 Jul 2022 08:41:18 +0200 Subject: [PATCH] get_stock_gl_code function called twice in the add_supp_invoice. Fixed. --- purchasing/includes/db/invoice_db.inc | 1 - 1 file changed, 1 deletion(-) diff --git a/purchasing/includes/db/invoice_db.inc b/purchasing/includes/db/invoice_db.inc index 545f064f..04909404 100644 --- a/purchasing/includes/db/invoice_db.inc +++ b/purchasing/includes/db/invoice_db.inc @@ -343,7 +343,6 @@ function add_supp_invoice(&$supp_trans) $ref = $Refs->get_next(ST_JOURNAL, null, $date_); add_journal(ST_JOURNAL, $id, $diff, $date_, get_company_currency(), $ref); $stock_id = $entered_grn->item_code; - $stock_gl_code = get_stock_gl_code($stock_id); $memo = _("Supplier invoice adjustment for zero inventory of ").$stock_id." "._("Invoice")." ".$supp_trans->reference; //Reverse the inventory effect if $qoh <=0 add_gl_trans_std_cost(ST_JOURNAL, $id, $date_, -- 2.30.2