Ignore:
Timestamp:
Jun 15, 2006 7:59:45 PM (18 years ago)
Author:
scdev
Message:

Q - added caching to ACL, and flush command to acl.cli.php

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/ScriptTimer.inc.php

    r136 r172  
    1818    function stop($name='default')
    1919    {
     20        if (!isset($this->_timing_stop_times[$name]) || !isset($this->_timing_cumulative_times[$name])) {
     21            $this->_timing_stop_times[$name] = null;
     22            $this->_timing_cumulative_times[$name] = null;
     23        }
    2024        $this->_timing_stop_times[$name] = explode(' ', microtime());
    2125        $this->_timing_cumulative_times[$name] += $this->getTime($name);
     
    2529    {
    2630        if (!isset($this->_timing_start_times[$name])) {
    27             return 0;
     31            return 0;
    2832        }
    2933        if (!isset($this->_timing_stop_times[$name])) {
     
    4852        }
    4953       
    50         $this->_timing_cumulative_times["TOTAL"] = array_sum($this->_timing_cumulative_times);
     54        $this->_timing_cumulative_times['TOTAL'] = array_sum($this->_timing_cumulative_times);
    5155
    5256        echo '<pre>';
Note: See TracChangeset for help on using the changeset viewer.