aboutsummaryrefslogtreecommitdiff
path: root/mod/developers/start.php
diff options
context:
space:
mode:
Diffstat (limited to 'mod/developers/start.php')
-rw-r--r--mod/developers/start.php11
1 files changed, 11 insertions, 0 deletions
diff --git a/mod/developers/start.php b/mod/developers/start.php
index 3c2f6bd5f..dc8e6f66e 100644
--- a/mod/developers/start.php
+++ b/mod/developers/start.php
@@ -3,6 +3,9 @@
* Elgg developer tools
*/
+// we want to run this as soon as possible - other plugins should not need to do this
+developers_process_settings();
+
elgg_register_event_handler('init', 'system', 'developers_init');
function developers_init() {
@@ -16,6 +19,14 @@ function developers_init() {
elgg_register_action('developers/settings', "$action_base/settings.php", 'admin');
}
+function developers_process_settings() {
+ if (elgg_get_plugin_setting('display_errors', 'developers') == 1) {
+ ini_set('display_errors', 1);
+ } else {
+ ini_set('display_errors', 0);
+ }
+}
+
function developers_setup_menu() {
if (elgg_in_context('admin')) {
elgg_register_admin_menu_item('develop', 'settings', 'developers');