Closed (fixed)
Project:
Ubercart
Version:
6.x-2.x-dev
Component:
Code
Priority:
Minor
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
21 Jan 2009 at 16:01 UTC
Updated:
10 Feb 2009 at 18:20 UTC
I am using beta3 version.
To eliminate a bunch of php notices, in uc_store.module add one line ($format = '';) to the function uc_currency_format as follows:
function uc_currency_format($value, $sign = TRUE, $thou = TRUE, $dec = NULL) {
if (variable_get('uc_currency_prec', 2) > 0) {
if (abs($value) < '.'. str_repeat('0', variable_get('uc_currency_prec', 2) - 1) .'1') {
$value = 0;
}
}
$format = ''; // Add this line here. Thanks.
if ($value < 0) {
$value = abs($value);
$format = '-';
}
...
Comments
Comment #1
Island Usurper commentedThanks. Committed.
If you want, try to round up all of the other places that are generating notices and we can get rid of them all at once.