diff options
author | Joas Schilling <nickvergessen@gmx.de> | 2014-06-25 21:48:24 +0200 |
---|---|---|
committer | Joas Schilling <nickvergessen@gmx.de> | 2014-07-06 19:31:46 +0200 |
commit | e3e0c79b7a8024ae25816b823c3ba5de19af62f2 (patch) | |
tree | 0fb25a9b8a5e1e600cf71083849b248b44d8701b /phpBB/phpbb/search/fulltext_postgres.php | |
parent | 5dd19c726e674cd0e436c1b89f57f41a1873b0ec (diff) | |
download | forums-e3e0c79b7a8024ae25816b823c3ba5de19af62f2.tar forums-e3e0c79b7a8024ae25816b823c3ba5de19af62f2.tar.gz forums-e3e0c79b7a8024ae25816b823c3ba5de19af62f2.tar.bz2 forums-e3e0c79b7a8024ae25816b823c3ba5de19af62f2.tar.xz forums-e3e0c79b7a8024ae25816b823c3ba5de19af62f2.zip |
[ticket/12515] Remove check for PostgreSQL 8.3+
PHPBB3-12515
Diffstat (limited to 'phpBB/phpbb/search/fulltext_postgres.php')
-rw-r--r-- | phpBB/phpbb/search/fulltext_postgres.php | 31 |
1 files changed, 2 insertions, 29 deletions
diff --git a/phpBB/phpbb/search/fulltext_postgres.php b/phpBB/phpbb/search/fulltext_postgres.php index 02e0870fd2..b3e7f51f87 100644 --- a/phpBB/phpbb/search/fulltext_postgres.php +++ b/phpBB/phpbb/search/fulltext_postgres.php @@ -31,18 +31,6 @@ class fulltext_postgres extends \phpbb\search\base protected $split_words = array(); /** - * True if PostgreSQL version supports tsearch - * @var boolean - */ - protected $tsearch_usable = false; - - /** - * Stores the PostgreSQL version - * @var string - */ - protected $version; - - /** * Stores the tsearch query * @var string */ @@ -107,16 +95,6 @@ class fulltext_postgres extends \phpbb\search\base $this->word_length = array('min' => $this->config['fulltext_postgres_min_word_len'], 'max' => $this->config['fulltext_postgres_max_word_len']); - if ($this->db->get_sql_layer() == 'postgres') - { - $pgsql_version = explode(',', substr($this->db->sql_server_info(), 10)); - $this->version = trim($pgsql_version[0]); - if (version_compare($this->version, '8.3', '>=')) - { - $this->tsearch_usable = true; - } - } - /** * Load the UTF tools */ @@ -190,11 +168,6 @@ class fulltext_postgres extends \phpbb\search\base return $this->user->lang['FULLTEXT_POSTGRES_INCOMPATIBLE_DATABASE']; } - if (!$this->tsearch_usable) - { - return $this->user->lang['FULLTEXT_POSTGRES_TS_NOT_USABLE']; - } - return false; } @@ -913,13 +886,13 @@ class fulltext_postgres extends \phpbb\search\base $tpl = ' <dl> <dt><label>' . $this->user->lang['FULLTEXT_POSTGRES_VERSION_CHECK'] . '</label><br /><span>' . $this->user->lang['FULLTEXT_POSTGRES_VERSION_CHECK_EXPLAIN'] . '</span></dt> - <dd>' . (($this->tsearch_usable) ? $this->user->lang['YES'] : $this->user->lang['NO']) . ' (PostgreSQL ' . $this->version . ')</dd> + <dd>' . (($this->db->get_sql_layer() == 'postgres') ? $this->user->lang['YES'] : $this->user->lang['NO']) . '</dd> </dl> <dl> <dt><label>' . $this->user->lang['FULLTEXT_POSTGRES_TS_NAME'] . '</label><br /><span>' . $this->user->lang['FULLTEXT_POSTGRES_TS_NAME_EXPLAIN'] . '</span></dt> <dd><select name="config[fulltext_postgres_ts_name]">'; - if ($this->db->get_sql_layer() == 'postgres' && $this->tsearch_usable) + if ($this->db->get_sql_layer() == 'postgres') { $sql = 'SELECT cfgname AS ts_name FROM pg_ts_config'; |