Type bugs.
[fa-stable.git] / purchasing / includes / db / grn_db.inc
index b055c1f94eb8b14a955b9f8afa302d9eaf04303a..d80fc0e1c9581d7d04762fa1fd4b5cce00382903 100644 (file)
@@ -21,7 +21,7 @@ function update_average_material_cost($supplier, $stock_id, $price, $qty, $date,
        $price = price_decimal_format($price, $dec);
        if ($currency != null)
        {
-               $ex_rate = get_exchange_rate_to_home_currency($currency, $date_);
+               $ex_rate = get_exchange_rate_to_home_currency($currency, $date);
                $price_in_home_currency = $price / $ex_rate;
                //$price_in_home_currency = to_home_currency($price, $currency, $date);
        }