diff options
author | Matt Friedman <maf675@gmail.com> | 2014-10-01 00:03:54 -0700 |
---|---|---|
committer | Matt Friedman <maf675@gmail.com> | 2014-10-01 00:03:54 -0700 |
commit | 65539df39a2649427f4208b836a65f2d8ca7b4b3 (patch) | |
tree | cfbc9a64a9f1f57b34265ae9de09046998143e02 /phpBB/phpbb/db | |
parent | 8fef959418fa43e04be051012c97657225644893 (diff) | |
download | forums-65539df39a2649427f4208b836a65f2d8ca7b4b3.tar forums-65539df39a2649427f4208b836a65f2d8ca7b4b3.tar.gz forums-65539df39a2649427f4208b836a65f2d8ca7b4b3.tar.bz2 forums-65539df39a2649427f4208b836a65f2d8ca7b4b3.tar.xz forums-65539df39a2649427f4208b836a65f2d8ca7b4b3.zip |
[ticket/13121] Remove cache mode from style management module
https://tracker.phpbb.com/browse/PHPBB3-13121
PHPBB3-13121
Diffstat (limited to 'phpBB/phpbb/db')
-rw-r--r-- | phpBB/phpbb/db/migration/data/v310/acp_style_cache_module.php | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/phpBB/phpbb/db/migration/data/v310/acp_style_cache_module.php b/phpBB/phpbb/db/migration/data/v310/acp_style_cache_module.php new file mode 100644 index 0000000000..a922a7cb78 --- /dev/null +++ b/phpBB/phpbb/db/migration/data/v310/acp_style_cache_module.php @@ -0,0 +1,51 @@ +<?php +/** +* +* This file is part of the phpBB Forum Software package. +* +* @copyright (c) phpBB Limited <https://www.phpbb.com> +* @license GNU General Public License, version 2 (GPL-2.0) +* +* For full copyright and license information, please see +* the docs/CREDITS.txt file. +* +*/ + +namespace phpbb\db\migration\data\v310; + +class acp_style_cache_module extends \phpbb\db\migration\migration +{ + public function effectively_installed() + { + $sql = 'SELECT module_id + FROM ' . MODULES_TABLE . " + WHERE module_class = 'acp' + AND module_langname = 'ACP_STYLES_CACHE'"; + $result = $this->db->sql_query($sql); + $module_id = $this->db->sql_fetchfield('module_id'); + $this->db->sql_freeresult($result); + + return $module_id == false; + } + + static public function depends_on() + { + return array('\phpbb\db\migration\data\v310\dev'); + } + + public function update_data() + { + return array( + array('module.remove', array( + 'acp', + 'ACP_STYLE_MANAGEMENT', + array( + 'module_basename' => 'acp_styles', + 'module_langname' => 'ACP_STYLES_CACHE', + 'module_mode' => 'cache', + 'module_auth' => 'acl_a_styles', + ), + )), + ); + } +} |