diff options
author | Thomas Steur <tsteur@users.noreply.github.com> | 2015-11-23 00:02:51 +0300 |
---|---|---|
committer | Thomas Steur <tsteur@users.noreply.github.com> | 2015-11-23 00:02:51 +0300 |
commit | bca533ad4369a2d8215cda113f3e2d7e1169213a (patch) | |
tree | 45c7a12173669942aa0ead525cbeaab072f07d0f | |
parent | 0d3ea495c12dbd5feccb15cd176a8f715be6a4bb (diff) | |
parent | 8ba27e27c3639bce8be5b41ac64851e9814a78c0 (diff) |
Merge pull request #9237 from piwik/profiler_allow_extension
Profiler: allow to use either Xhprof PHP extension or locally built Xhprof from composer
-rw-r--r-- | core/Profiler.php | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/core/Profiler.php b/core/Profiler.php index c1b0875fa6..12c1e46ff6 100644 --- a/core/Profiler.php +++ b/core/Profiler.php @@ -209,13 +209,9 @@ class Profiler return; } - $xhProfPath = PIWIK_INCLUDE_PATH . '/vendor/facebook/xhprof/extension/modules/xhprof.so'; - if (!file_exists($xhProfPath)) { - throw new Exception("Cannot find xhprof, run 'composer install --dev' and build the extension."); - } - if (!function_exists('xhprof_enable')) { - throw new Exception("Cannot find xhprof_enable, make sure to add 'extension=$xhProfPath' to your php.ini."); + $xhProfPath = PIWIK_INCLUDE_PATH . '/vendor/facebook/xhprof/extension/modules/xhprof.so'; + throw new Exception("Cannot find xhprof_enable, make sure to 1) install xhprof: run 'composer install --dev' and build the extension, and 2) add 'extension=$xhProfPath' to your php.ini."); } $outputDir = ini_get("xhprof.output_dir"); |