Ignore:
Timestamp:
Apr 27, 2017, 11:48:42 AM (10 years ago)
Author:
Joachim Langenbach <joachim.langenbach@…>
Branches:
0.5, app-cordova, debian/bullseye, debian/jessie, master
Children:
06c0abb, 12afe34, 22f7269
Parents:
00a8800 (diff), 19ac332 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' of ​https://svn.falaba.de/gnuboat

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/webapp/webservice/index.php

    r00a8800 rc84f87e  
    1616    along with this program.  If not, see <http://www.gnu.org/licenses/>.
    1717*/
     18
     19xdebug_start_trace();
    1820
    1921require_once(__DIR__ ."/inc/Config.php");
    … …  
    6870        $lastTime = -1;
    6971        $keys = array_keys($data);
    70         if(count($keys) < 0 ){
     72        $keyTimeframes = $keys[0];
     73        $itemCount = count($keys);
     74        if($itemCount < 0 ){
    7175                error_log("No keys in fetched rrd data from ". $dbFile);
    7276                echo json_encode("");
    7377                exit;
    7478        }
     79        $timeframesCount = count($data[$keyTimeframes]);
    7580        if($debug > 0){
    76                 echo "<p>Variables: ". count($keys) ."; Timeframes: ". count($data[$keys[0]]) ."</p>\n";
     81                echo "<p>Variables: ". $itemCount ."; Timeframes: ". $timeframesCount ."</p>\n";
    7782        }
    7883        foreach($data[$keys[0]] as $timeframe => $value){
    … …  
    185190}
    186191
     192xdebug_stop_trace();
     193
    187194?>
Note: See TracChangeset for help on using the changeset viewer.