From a3ccd8e86e990d9e66afd33bfd79d26670d6177e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20S=CC=8Ckoda?= Date: Sun, 2 Jun 2013 13:33:20 +0200 Subject: [PATCH] MDL-39416 do not try to get detailed perflog info before PAGE int --- lib/moodlelib.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/moodlelib.php b/lib/moodlelib.php index 542be228110..277b4967212 100644 --- a/lib/moodlelib.php +++ b/lib/moodlelib.php @@ -10343,6 +10343,11 @@ function get_performance_info() { $info['html'] .= 'Included '.$info['includecount'].' files '; $info['txt'] .= 'includecount: '.$info['includecount'].' '; + if (!empty($CFG->early_install_lang) or empty($PAGE)) { + // We can not track more performance before installation or before PAGE init, sorry. + return $info; + } + $filtermanager = filter_manager::instance(); if (method_exists($filtermanager, 'get_performance_summary')) { list($filterinfo, $nicenames) = $filtermanager->get_performance_summary();