aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/captcha
diff options
context:
space:
mode:
authorNicofuma <github@nicofuma.fr>2015-02-09 17:11:09 +0100
committerNicofuma <github@nicofuma.fr>2015-02-09 17:11:09 +0100
commitacf3744297303324490c484156f0bf808e532883 (patch)
tree5dfae513699ce84bbdf0028842732695df7c7e47 /phpBB/phpbb/captcha
parentb0c910e49c31e086f19f983bb9d7d5051d34fac8 (diff)
parent74d1b1812f512ae232a063a2574d62d3f5491f46 (diff)
downloadforums-acf3744297303324490c484156f0bf808e532883.tar
forums-acf3744297303324490c484156f0bf808e532883.tar.gz
forums-acf3744297303324490c484156f0bf808e532883.tar.bz2
forums-acf3744297303324490c484156f0bf808e532883.tar.xz
forums-acf3744297303324490c484156f0bf808e532883.zip
Merge pull request #3332 from nickvergessen/ticket/10748-mssql
[ticket/10748] Split MS SQL from the db tools file into it's own
Diffstat (limited to 'phpBB/phpbb/captcha')
-rw-r--r--phpBB/phpbb/captcha/plugins/qa.php12
1 files changed, 5 insertions, 7 deletions
diff --git a/phpBB/phpbb/captcha/plugins/qa.php b/phpBB/phpbb/captcha/plugins/qa.php
index b4586f1234..cf03f92e96 100644
--- a/phpBB/phpbb/captcha/plugins/qa.php
+++ b/phpBB/phpbb/captcha/plugins/qa.php
@@ -113,9 +113,9 @@ class qa
*/
public function is_installed()
{
- global $db;
+ global $phpbb_container;
- $db_tool = new \phpbb\db\tools\tools($db);
+ $db_tool = $phpbb_container->get('dbal.tools');
return $db_tool->sql_table_exists($this->table_captcha_questions);
}
@@ -306,11 +306,9 @@ class qa
*/
function install()
{
- global $db;
-
- $db_tool = new \phpbb\db\tools\tools($db);
+ global $phpbb_container;
- $tables = array($this->table_captcha_questions, $this->table_captcha_answers, $this->table_qa_confirm);
+ $db_tool = $phpbb_container->get('dbal.tools');
$schemas = array(
$this->table_captcha_questions => array (
@@ -352,7 +350,7 @@ class qa
),
);
- foreach($schemas as $table => $schema)
+ foreach ($schemas as $table => $schema)
{
if (!$db_tool->sql_table_exists($table))
{