mirror of
https://github.com/friendica/friendica
synced 2025-04-26 17:10:10 +00:00
Generate callstack value from inside Profiler::saveTimestamp
- Save a massive amount of time computing callstacks when profiling is disabled
This commit is contained in:
parent
19141b1bcf
commit
afb882048e
13 changed files with 42 additions and 39 deletions
|
@ -1098,7 +1098,7 @@ class BBCode
|
|||
@curl_exec($ch);
|
||||
$curl_info = @curl_getinfo($ch);
|
||||
|
||||
DI::profiler()->saveTimestamp($stamp1, "network", System::callstack());
|
||||
DI::profiler()->saveTimestamp($stamp1, "network");
|
||||
|
||||
if (substr($curl_info['content_type'], 0, 6) == 'image/') {
|
||||
$text = "[url=" . $match[1] . ']' . $match[1] . "[/url]";
|
||||
|
@ -1172,7 +1172,7 @@ class BBCode
|
|||
@curl_exec($ch);
|
||||
$curl_info = @curl_getinfo($ch);
|
||||
|
||||
DI::profiler()->saveTimestamp($stamp1, "network", System::callstack());
|
||||
DI::profiler()->saveTimestamp($stamp1, "network");
|
||||
|
||||
// if its a link to a picture then embed this picture
|
||||
if (substr($curl_info['content_type'], 0, 6) == 'image/') {
|
||||
|
@ -2045,7 +2045,7 @@ class BBCode
|
|||
// Now convert HTML to Markdown
|
||||
$text = HTML::toMarkdown($text);
|
||||
|
||||
DI::profiler()->saveTimestamp($stamp1, "parser", System::callstack());
|
||||
DI::profiler()->saveTimestamp($stamp1, "parser");
|
||||
|
||||
// Libertree has a problem with escaped hashtags.
|
||||
$text = str_replace(['\#'], ['#'], $text);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue