diff options
| author | Máté Bartus <CHItA@users.noreply.github.com> | 2017-09-07 14:12:18 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-09-07 14:12:18 +0200 |
| commit | 384ece3621b1f6e0f97e2ce2208a990d4a03f407 (patch) | |
| tree | e6e1f347e85fbc7b6d5bba5da9ad1ae10ff71926 /phpBB | |
| parent | 9c0bb4afb583169d42a5f5ae3cb91d6c0a9449b7 (diff) | |
| parent | d99dbf1f0ea08e69be4fd61df2a45bbf1f0b1340 (diff) | |
| download | forums-384ece3621b1f6e0f97e2ce2208a990d4a03f407.tar forums-384ece3621b1f6e0f97e2ce2208a990d4a03f407.tar.gz forums-384ece3621b1f6e0f97e2ce2208a990d4a03f407.tar.bz2 forums-384ece3621b1f6e0f97e2ce2208a990d4a03f407.tar.xz forums-384ece3621b1f6e0f97e2ce2208a990d4a03f407.zip | |
Merge pull request #4924 from rubencm/ticket/15346
[ticket/15346] Check if extension is enableable during install
Diffstat (limited to 'phpBB')
| -rw-r--r-- | phpBB/language/en/cli.php | 1 | ||||
| -rw-r--r-- | phpBB/phpbb/install/module/install_finish/task/install_extensions.php | 8 |
2 files changed, 9 insertions, 0 deletions
diff --git a/phpBB/language/en/cli.php b/phpBB/language/en/cli.php index 124d9cb6ef..1655855edb 100644 --- a/phpBB/language/en/cli.php +++ b/phpBB/language/en/cli.php @@ -123,6 +123,7 @@ $lang = array_merge($lang, array( 'CLI_EXTENSION_UPDATE_FAILURE' => 'Could not update extension %s', 'CLI_EXTENSION_UPDATE_SUCCESS' => 'Successfully updated extension %s', 'CLI_EXTENSION_NOT_FOUND' => 'No extensions were found.', + 'CLI_EXTENSION_NOT_ENABLEABLE' => 'Extension %s is not enableable.', 'CLI_EXTENSIONS_AVAILABLE' => 'Available', 'CLI_EXTENSIONS_DISABLED' => 'Disabled', 'CLI_EXTENSIONS_ENABLED' => 'Enabled', diff --git a/phpBB/phpbb/install/module/install_finish/task/install_extensions.php b/phpBB/phpbb/install/module/install_finish/task/install_extensions.php index 553a30ea28..eee13a6581 100644 --- a/phpBB/phpbb/install/module/install_finish/task/install_extensions.php +++ b/phpBB/phpbb/install/module/install_finish/task/install_extensions.php @@ -118,6 +118,14 @@ class install_extensions extends \phpbb\install\task_base try { + $extension = $this->extension_manager->get_extension($ext_name); + + if (!$extension->is_enableable()) + { + $this->iohandler->add_log_message(array('CLI_EXTENSION_NOT_ENABLEABLE', $ext_name)); + continue; + } + $this->extension_manager->enable($ext_name); $extensions = $this->get_extensions(); |
