summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2010-12-16 20:37:44 -0800
committerBharat Mediratta <bharat@menalto.com>2010-12-16 20:37:44 -0800
commit161a85d3f5a6e8ed5835b901eb1d08e07e40be81 (patch)
treeeeacfb00952fe9582c5b60e04c2dac6ccad8eb08
parent7e31f97b4cbc5cf1894611de1e9de7a3efc6ad50 (diff)
Enable profiling output in the HTML output for REST. Fixes #1535.
-rw-r--r--modules/rest/helpers/rest.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/modules/rest/helpers/rest.php b/modules/rest/helpers/rest.php
index 9406e209..676c10c3 100644
--- a/modules/rest/helpers/rest.php
+++ b/modules/rest/helpers/rest.php
@@ -54,6 +54,11 @@ class rest_Core {
$html = t("Empty response");
}
print "<pre>$html</pre>";
+ if (Session::instance()->get("profiler", false)) {
+ Profiler::enable();
+ $profiler = new Profiler();
+ $profiler->render();
+ }
break;
default: