diff options
author | Tristan Darricau <github@nicofuma.fr> | 2014-07-13 15:44:58 +0200 |
---|---|---|
committer | Tristan Darricau <github@nicofuma.fr> | 2014-07-13 18:09:34 +0200 |
commit | 519e64205a50b15efa8589901c87f5b21448993a (patch) | |
tree | 82ab03bbf7315f42857d45badd32b00a636c8c49 /phpBB/phpbb/extension/manager.php | |
parent | dd78b564e56152be559b4ec476e35698fa32e1bf (diff) | |
download | forums-519e64205a50b15efa8589901c87f5b21448993a.tar forums-519e64205a50b15efa8589901c87f5b21448993a.tar.gz forums-519e64205a50b15efa8589901c87f5b21448993a.tar.bz2 forums-519e64205a50b15efa8589901c87f5b21448993a.tar.xz forums-519e64205a50b15efa8589901c87f5b21448993a.zip |
[ticket/12847] Allow the extensions to say if they can be enabled
PHPBB3-12847
Diffstat (limited to 'phpBB/phpbb/extension/manager.php')
-rw-r--r-- | phpBB/phpbb/extension/manager.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/phpBB/phpbb/extension/manager.php b/phpBB/phpbb/extension/manager.php index b19eb9f8a3..5afec9ba82 100644 --- a/phpBB/phpbb/extension/manager.php +++ b/phpBB/phpbb/extension/manager.php @@ -177,6 +177,12 @@ class manager $old_state = (isset($this->extensions[$name]['ext_state'])) ? unserialize($this->extensions[$name]['ext_state']) : false; $extension = $this->get_extension($name); + + if (!$extension->is_enableable()) + { + return false; + } + $state = $extension->enable_step($old_state); $active = ($state === false); |