diff options
author | Joseph Warner <hardolaf@hardolaf.com> | 2013-07-14 14:17:54 -0400 |
---|---|---|
committer | Joseph Warner <hardolaf@hardolaf.com> | 2013-07-14 14:22:43 -0400 |
commit | 00d0e102008767f712145f55348a662f3e6750d6 (patch) | |
tree | 005c2257b1c8f30a2cb139af1b56d23f4e85dec0 /phpBB/phpbb/db | |
parent | a43a8f8c72f14b683f7db39a20c6d5fc4f154744 (diff) | |
download | forums-00d0e102008767f712145f55348a662f3e6750d6.tar forums-00d0e102008767f712145f55348a662f3e6750d6.tar.gz forums-00d0e102008767f712145f55348a662f3e6750d6.tar.bz2 forums-00d0e102008767f712145f55348a662f3e6750d6.tar.xz forums-00d0e102008767f712145f55348a662f3e6750d6.zip |
[feature/oauth] Move last file to appropriate location
PHPBB3-11673
Diffstat (limited to 'phpBB/phpbb/db')
-rw-r--r-- | phpBB/phpbb/db/migration/data/310/auth_provider_oauth.php | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/phpBB/phpbb/db/migration/data/310/auth_provider_oauth.php b/phpBB/phpbb/db/migration/data/310/auth_provider_oauth.php new file mode 100644 index 0000000000..92da42ba31 --- /dev/null +++ b/phpBB/phpbb/db/migration/data/310/auth_provider_oauth.php @@ -0,0 +1,45 @@ +<?php +/** +* +* @package migration +* @copyright (c) 2013 phpBB Group +* @license http://opensource.org/licenses/gpl-license.php GNU Public License v2 +* +*/ + +class phpbb_db_migration_data_310_auth_provider_oauth extends phpbb_db_migration +{ + public function effectively_installed() + { + return $this->db_tools->sql_table_exists($this->table_prefix . 'auth_provider_oauth'); + } + + public function update_schema() + { + return array( + 'add_tables' => array( + $this->table_prefix . 'auth_provider_oauth' => array( + 'COLUMNS' => array( + 'user_id' => array('UINT', 0), // phpbb_users.user_id + 'session_id' => array('CHAR:32', ''), // phpbb_sessions.session_id used only when user_id not set + 'oauth_provider' => array('VCHAR'), // Name of the OAuth provider + 'oauth_token' => array('TEXT_UNI'), // Serialized token + ), + 'KEYS' => array( + 'user_id' => array('INDEX', 'user_id'), + 'oauth_provider' => array('INDEX', 'oauth_provider'), + ), + ), + ), + ); + } + + public function revert_schema() + { + return array( + 'drop_tables' => array( + $this->table_prefix . 'auth_provider_oauth', + ), + ); + } +} |