diff --git a/phpBB/includes/acp/acp_board.php b/phpBB/includes/acp/acp_board.php index 8061265e11..d41a1c010a 100644 --- a/phpBB/includes/acp/acp_board.php +++ b/phpBB/includes/acp/acp_board.php @@ -215,8 +215,6 @@ class acp_board 'max_post_urls' => array('lang' => 'MAX_POST_URLS', 'validate' => 'int:0:9999', 'type' => 'number:0:9999', 'explain' => true), 'max_post_font_size' => array('lang' => 'MAX_POST_FONT_SIZE', 'validate' => 'int:0:9999', 'type' => 'number:0:9999', 'explain' => true, 'append' => ' %'), 'max_quote_depth' => array('lang' => 'QUOTE_DEPTH_LIMIT', 'validate' => 'int:0:9999', 'type' => 'number:0:9999', 'explain' => true), - 'max_post_img_width' => array('lang' => 'MAX_POST_IMG_WIDTH', 'validate' => 'int:0:9999', 'type' => 'number:0:9999', 'explain' => true, 'append' => ' ' . $user->lang['PIXEL']), - 'max_post_img_height' => array('lang' => 'MAX_POST_IMG_HEIGHT', 'validate' => 'int:0:9999', 'type' => 'number:0:9999', 'explain' => true, 'append' => ' ' . $user->lang['PIXEL']), 'legend3' => 'MENTIONS', 'allow_mentions' => array('lang' => 'ALLOW_MENTIONS', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => false), diff --git a/phpBB/includes/questionnaire/questionnaire.php b/phpBB/includes/questionnaire/questionnaire.php index cdb70ef2f1..d5eb1daf7c 100644 --- a/phpBB/includes/questionnaire/questionnaire.php +++ b/phpBB/includes/questionnaire/questionnaire.php @@ -400,8 +400,6 @@ class phpbb_questionnaire_phpbb_data_provider 'max_poll_options' => true, 'max_post_chars' => true, 'max_post_font_size' => true, - 'max_post_img_height' => true, - 'max_post_img_width' => true, 'max_post_smilies' => true, 'max_post_urls' => true, 'max_quote_depth' => true, diff --git a/phpBB/install/schemas/schema_data.sql b/phpBB/install/schemas/schema_data.sql index a429d720aa..c3a3ff9876 100644 --- a/phpBB/install/schemas/schema_data.sql +++ b/phpBB/install/schemas/schema_data.sql @@ -220,8 +220,6 @@ INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_num_search_key INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_poll_options', '10'); INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_chars', '60000'); INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_font_size', '200'); -INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_img_height', '0'); -INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_img_width', '0'); INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_smilies', '0'); INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_post_urls', '0'); INSERT INTO phpbb_config (config_name, config_value) VALUES ('max_quote_depth', '3'); diff --git a/phpBB/phpbb/db/migration/data/v400/remove_flash_v2.php b/phpBB/phpbb/db/migration/data/v400/remove_flash_v2.php new file mode 100644 index 0000000000..5312cc7c83 --- /dev/null +++ b/phpBB/phpbb/db/migration/data/v400/remove_flash_v2.php @@ -0,0 +1,39 @@ + +* @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\v400; + +use phpbb\db\migration\migration; + +class remove_flash_v2 extends migration +{ + public function effectively_installed() + { + return !$this->config->offsetExists('max_post_img_width'); + } + + public static function depends_on() + { + return [ + '\phpbb\db\migration\data\v400\remove_flash', + ]; + } + + public function update_data() + { + return [ + ['config.remove', ['max_post_img_width']], + ['config.remove', ['max_post_img_height']], + ]; + } +} diff --git a/tests/text_processing/message_parser_test.php b/tests/text_processing/message_parser_test.php index 22496a8505..0f74eacbe6 100644 --- a/tests/text_processing/message_parser_test.php +++ b/tests/text_processing/message_parser_test.php @@ -315,26 +315,6 @@ class phpbb_text_processing_message_parser_test extends phpbb_test_case }, array('You may only use fonts up to size 120.') ), - array( - '[img]http://example.org/100x100.png[/img]', - '[img]http://example.org/100x100.png[/img]', - array(true, true, true, true, true, true), - function ($phpbb_container) - { - $phpbb_container->get('config')->set('max_post_img_height', 0); - $phpbb_container->get('config')->set('max_post_img_width', 0); - } - ), - array( - '[img]http://example.org/100x100.png[/img]', - '[img]http://example.org/100x100.png[/img]', - array(true, true, true, true, true, true), - function ($phpbb_container) - { - $phpbb_container->get('config')->set('max_post_img_height', 100); - $phpbb_container->get('config')->set('max_post_img_width', 100); - } - ), array( '[img]http://example.org/100x100.png[/img]', '[img]http://example.org/100x100.png[/img]',