aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/db
diff options
context:
space:
mode:
authorMarc Alexander <admin@m-a-styles.de>2019-08-09 22:43:04 +0200
committerMarc Alexander <admin@m-a-styles.de>2019-08-09 22:47:04 +0200
commitf41c51d1ecc36bc6e5dffc70ad7a5ed50d4ec7ea (patch)
treeb3580a9615a5790b133c47ea4eedf2be61967193 /phpBB/phpbb/db
parentfe030f67efc354729033ebc1726fc5b729057fb2 (diff)
downloadforums-f41c51d1ecc36bc6e5dffc70ad7a5ed50d4ec7ea.tar
forums-f41c51d1ecc36bc6e5dffc70ad7a5ed50d4ec7ea.tar.gz
forums-f41c51d1ecc36bc6e5dffc70ad7a5ed50d4ec7ea.tar.bz2
forums-f41c51d1ecc36bc6e5dffc70ad7a5ed50d4ec7ea.tar.xz
forums-f41c51d1ecc36bc6e5dffc70ad7a5ed50d4ec7ea.zip
[ticket/11327] Add reset token columns & config setting
PHPBB3-11327
Diffstat (limited to 'phpBB/phpbb/db')
-rw-r--r--phpBB/phpbb/db/migration/data/v330/reset_password.php48
1 files changed, 48 insertions, 0 deletions
diff --git a/phpBB/phpbb/db/migration/data/v330/reset_password.php b/phpBB/phpbb/db/migration/data/v330/reset_password.php
new file mode 100644
index 0000000000..87131c6e93
--- /dev/null
+++ b/phpBB/phpbb/db/migration/data/v330/reset_password.php
@@ -0,0 +1,48 @@
+<?php
+/**
+ *
+ * This file is part of the phpBB Forum Software package.
+ *
+ * @copyright (c) phpBB Limited <https://www.phpbb.com>
+ * @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\v330;
+
+class reset_password extends \phpbb\db\migration\migration
+{
+ static public function depends_on()
+ {
+ return array(
+ '\phpbb\db\migration\data\v330\dev',
+ );
+ }
+
+ public function update_schema()
+ {
+ return [
+ 'add_columns' => [
+ $this->table_prefix . 'users' => [
+ 'reset_token' => ['VCHAR:64', '', 'after' => 'user_actkey'],
+ 'reset_token_expiration' => ['TIMESTAMP', 0, 'after' => 'reset_token'],
+ ],
+ ],
+ ];
+ }
+
+ public function revert_schema()
+ {
+ return [
+ 'drop_columns' => [
+ $this->table_prefix . 'users' => [
+ 'reset_token',
+ 'reset_token_expiration',
+ ],
+ ],
+ ];
+ }
+}