Makes save_timestamp conditional
- Add a .htconfig check to save_timestamp to prevent systematic profiling - Removes unused `mark_timestamp()` function including deleted code comment
This commit is contained in:
parent
a5923bdd4f
commit
74ce4c2710
8
boot.php
8
boot.php
|
@ -1100,6 +1100,9 @@ class App {
|
||||||
}
|
}
|
||||||
|
|
||||||
function save_timestamp($stamp, $value) {
|
function save_timestamp($stamp, $value) {
|
||||||
|
if (!isset($a->config['system']['profiler']) || !$a->config['system']['profiler'])
|
||||||
|
return;
|
||||||
|
|
||||||
$duration = (float)(microtime(true)-$stamp);
|
$duration = (float)(microtime(true)-$stamp);
|
||||||
|
|
||||||
if (!isset($this->performance[$value])) {
|
if (!isset($this->performance[$value])) {
|
||||||
|
@ -1176,11 +1179,6 @@ class App {
|
||||||
return implode(", ", $callstack);
|
return implode(", ", $callstack);
|
||||||
}
|
}
|
||||||
|
|
||||||
function mark_timestamp($mark) {
|
|
||||||
//$this->performance["markstart"] -= microtime(true) - $this->performance["marktime"];
|
|
||||||
$this->performance["markstart"] = microtime(true) - $this->performance["markstart"] - $this->performance["marktime"];
|
|
||||||
}
|
|
||||||
|
|
||||||
function get_useragent() {
|
function get_useragent() {
|
||||||
return(FRIENDICA_PLATFORM." '".FRIENDICA_CODENAME."' ".FRIENDICA_VERSION."-".DB_UPDATE_VERSION."; ".$this->get_baseurl());
|
return(FRIENDICA_PLATFORM." '".FRIENDICA_CODENAME."' ".FRIENDICA_VERSION."-".DB_UPDATE_VERSION."; ".$this->get_baseurl());
|
||||||
}
|
}
|
||||||
|
|
|
@ -145,7 +145,6 @@ class Conversation extends BaseObject {
|
||||||
$result[] = $item_data;
|
$result[] = $item_data;
|
||||||
}
|
}
|
||||||
|
|
||||||
//$a->mark_timestamp();
|
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue