aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNils Adermann <naderman@naderman.de>2011-06-12 23:09:52 +0200
committerNils Adermann <naderman@naderman.de>2011-06-12 23:09:52 +0200
commitb65cf4c8d6f4d97f9db6dbb612072b3a999158da (patch)
tree0329ffa5349a415be0f92777d44b57f4f80f1931
parentf1998ddbc712015562b8e16fdc0f42a4c85ae82e (diff)
downloadforums-b65cf4c8d6f4d97f9db6dbb612072b3a999158da.tar
forums-b65cf4c8d6f4d97f9db6dbb612072b3a999158da.tar.gz
forums-b65cf4c8d6f4d97f9db6dbb612072b3a999158da.tar.bz2
forums-b65cf4c8d6f4d97f9db6dbb612072b3a999158da.tar.xz
forums-b65cf4c8d6f4d97f9db6dbb612072b3a999158da.zip
[ticket/9992] The table name constant needs to be defined in the updater
When the database update is run before updating the files the constant is not yet defined. PHPBB3-9992
-rw-r--r--phpBB/install/database_update.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/phpBB/install/database_update.php b/phpBB/install/database_update.php
index 24a69ab99b..935fe70b9c 100644
--- a/phpBB/install/database_update.php
+++ b/phpBB/install/database_update.php
@@ -78,6 +78,13 @@ require($phpbb_root_path . 'includes/constants.' . $phpEx);
require($phpbb_root_path . 'includes/db/' . $dbms . '.' . $phpEx);
require($phpbb_root_path . 'includes/utf/utf_tools.' . $phpEx);
+// new table constants are separately defined here in case the updater is run
+// before the files are updated
+if (!defined('LOGIN_ATTEMPT_TABLE'))
+{
+ define('LOGIN_ATTEMPT_TABLE', $table_prefix . 'login_attempts');
+}
+
// If we are on PHP >= 6.0.0 we do not need some code
if (version_compare(PHP_VERSION, '6.0.0-dev', '>='))
{