aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB
diff options
context:
space:
mode:
authorMarc Alexander <admin@m-a-styles.de>2018-11-18 12:24:16 +0100
committerMarc Alexander <admin@m-a-styles.de>2018-11-18 12:24:16 +0100
commit5b3eb2d61cd148db896b3dd9fa4e541752294aae (patch)
tree89ab63acfff47c34e1694b54209f28676d36ef22 /phpBB
parent97912d74e2f2e0e98662a590cc2e34ac929bd725 (diff)
parentaf1e8901e5108750dc9ad65f6efe22fa93482c9a (diff)
downloadforums-5b3eb2d61cd148db896b3dd9fa4e541752294aae.tar
forums-5b3eb2d61cd148db896b3dd9fa4e541752294aae.tar.gz
forums-5b3eb2d61cd148db896b3dd9fa4e541752294aae.tar.bz2
forums-5b3eb2d61cd148db896b3dd9fa4e541752294aae.tar.xz
forums-5b3eb2d61cd148db896b3dd9fa4e541752294aae.zip
Merge pull request #5442 from rxu/ticket/15871
[ticket/15871] Fix PHP 7.1+ warning in ACP extensions module
Diffstat (limited to 'phpBB')
-rw-r--r--phpBB/includes/acp/acp_extensions.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/phpBB/includes/acp/acp_extensions.php b/phpBB/includes/acp/acp_extensions.php
index 6f65dc9fa0..a1cb2108e7 100644
--- a/phpBB/includes/acp/acp_extensions.php
+++ b/phpBB/includes/acp/acp_extensions.php
@@ -35,11 +35,13 @@ class acp_extensions
private $request;
private $phpbb_dispatcher;
private $ext_manager;
+ private $phpbb_container;
+ private $php_ini;
function main()
{
// Start the page
- global $config, $user, $template, $request, $phpbb_extension_manager, $phpbb_root_path, $phpbb_log, $phpbb_dispatcher;
+ global $config, $user, $template, $request, $phpbb_extension_manager, $phpbb_root_path, $phpbb_log, $phpbb_dispatcher, $phpbb_container;
$this->config = $config;
$this->template = $template;
@@ -48,6 +50,8 @@ class acp_extensions
$this->log = $phpbb_log;
$this->phpbb_dispatcher = $phpbb_dispatcher;
$this->ext_manager = $phpbb_extension_manager;
+ $this->phpbb_container = $phpbb_container;
+ $this->php_ini = $this->phpbb_container->get('php_ini');
$this->user->add_lang(array('install', 'acp/extensions', 'migrator'));
@@ -57,7 +61,7 @@ class acp_extensions
$ext_name = $this->request->variable('ext_name', '');
// What is a safe limit of execution time? Half the max execution time should be safe.
- $safe_time_limit = (ini_get('max_execution_time') / 2);
+ $safe_time_limit = ($this->php_ini->getNumeric('max_execution_time') / 2);
$start_time = time();
// Cancel action