diff options
author | JoshyPHP <s9e.dev@gmail.com> | 2015-05-02 02:55:45 +0200 |
---|---|---|
committer | JoshyPHP <s9e.dev@gmail.com> | 2015-05-30 17:26:00 +0200 |
commit | 9bf0f794b5876b10491c91548f1a92bc0dff7400 (patch) | |
tree | 3da5c0d8e5a9b7d9bd99cd75a055d5f00a4477eb /phpBB/phpbb/textreparser/row_based_plugin.php | |
parent | ea445ffa4776b7ce0b1d13485f113c7e1ec28af0 (diff) | |
download | forums-9bf0f794b5876b10491c91548f1a92bc0dff7400.tar forums-9bf0f794b5876b10491c91548f1a92bc0dff7400.tar.gz forums-9bf0f794b5876b10491c91548f1a92bc0dff7400.tar.bz2 forums-9bf0f794b5876b10491c91548f1a92bc0dff7400.tar.xz forums-9bf0f794b5876b10491c91548f1a92bc0dff7400.zip |
[ticket/13803] Added pm_text tests
PHPBB3-13803
Diffstat (limited to 'phpBB/phpbb/textreparser/row_based_plugin.php')
-rw-r--r-- | phpBB/phpbb/textreparser/row_based_plugin.php | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/phpBB/phpbb/textreparser/row_based_plugin.php b/phpBB/phpbb/textreparser/row_based_plugin.php index 80525a404e..e39ec4d5d3 100644 --- a/phpBB/phpbb/textreparser/row_based_plugin.php +++ b/phpBB/phpbb/textreparser/row_based_plugin.php @@ -45,38 +45,6 @@ abstract class row_based_plugin extends base abstract public function get_table_name(); /** - * Add fields to given row, if applicable - * - * The enable_* fields are not always saved to the database. Sometimes we need to guess their - * original value based on the text content or possibly other fields - * - * @param array $row Original row - * @return array Complete row - */ - protected function add_missing_fields(array $row) - { - if (!isset($row['enable_bbcode'], $row['enable_smilies'], $row['enable_magic_url'])) - { - $row += array( - 'enable_bbcode' => !empty($row['bbcode_uid']), - 'enable_smilies' => $this->guess_smilies($row), - 'enable_magic_url' => $this->guess_magic_url($row), - ); - } - - // Those BBCodes are disabled based on context and user permissions and that value is never - // stored in the database. Here we test whether they were used in the original text. - $bbcodes = array('flash', 'img', 'quote', 'url'); - foreach ($bbcodes as $bbcode) - { - $field_name = 'enable_' . $bbcode; - $row[$field_name] = $this->guess_bbcode($row, $bbcode); - } - - return $row; - } - - /** * {@inheritdoc} */ public function get_max_id() |