X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Frep451.php;h=28bdae6a7182b6e44a51b2cae074e156df92c2a2;hb=3977695ae8f6c065a6eaa12d18812623e0e17181;hp=ece0519b7af61ec3df4d7ea896b504483368736e;hpb=89d9b659abe59b9ee1357b3f08857f8f0e43e425;p=fa-stable.git diff --git a/reporting/rep451.php b/reporting/rep451.php index ece0519b..28bdae6a 100644 --- a/reporting/rep451.php +++ b/reporting/rep451.php @@ -33,7 +33,7 @@ function find_last_location($stock_id, $end_date) tran_date <= '$end_date' ORDER BY tran_date DESC LIMIT 1"; $res = db_query($sql,"No stock moves were returned"); $row = db_fetch_row($res); - return $row[0]; + return is_array($row) ? $row[0] : false; } //----------------------------------------------------------------------------------------------------