diff --git a/build/api/module/fetchDefault.php b/build/api/module/fetchDefault.php index a41a5ec..ceb8aed 100644 --- a/build/api/module/fetchDefault.php +++ b/build/api/module/fetchDefault.php @@ -136,11 +136,12 @@ /* (2) Calcl the total to add */ $total = 0; + foreach($data as $entry){ // Only if positive numeric - if( is_numeric($entry) && $entry > 0 ) - $total += intval($entry); + if( isset($entry[0]) && is_numeric($entry[0]) && $entry[0] > 0 ) + $total += intval($entry[0]); $count++; }