From: Joe Hunt Date: Wed, 1 Nov 2017 08:54:18 +0000 (+0100) Subject: More index and constructs fixes. X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=commitdiff_plain;h=ae07ee0e4b86f85cea49dc14f45fd3fd04150026;p=fa-stable.git More index and constructs fixes. --- diff --git a/includes/current_user.inc b/includes/current_user.inc index 74a8035f..e6f05188 100644 --- a/includes/current_user.inc +++ b/includes/current_user.inc @@ -305,6 +305,8 @@ function number_format2($number, $decimals=0) $tsep = $SysPrefs->thoseps[user_tho_sep()]; $dsep = $SysPrefs->decseps[user_dec_sep()]; + if ($number == '') + $number = 0; if($decimals==='max') $dec = 15 - floor(log10(abs($number))); else { diff --git a/includes/errors.inc b/includes/errors.inc index a4618e8d..53587df6 100644 --- a/includes/errors.inc +++ b/includes/errors.inc @@ -21,7 +21,8 @@ function get_backtrace($html = false, $skip=0) foreach($trace as $trn => $tr) { if ($trn <= $skip) continue; if ($html) $str .= ''; - $str .= $tr['file'].':'.$tr['line'].': '; + if (isset($tr['file']) && isset($tr['line'])) + $str .= $tr['file'].':'.$tr['line'].': '; if ($html) $str .= ''; if (isset($tr['type'])) { if($tr['type'] == '::') {