diff options
author | Joram Wilander <jwawilander@gmail.com> | 2017-08-01 11:06:53 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-08-01 11:06:53 -0400 |
commit | 5da5c0bbfb80cb5c9cf2699f42d17decc2d60f5b (patch) | |
tree | fdd886332e75a9ae8138a31d3c34b240adb094b5 /store | |
parent | 4ef844298fdb0d6fb41eac760f8ac00cee82b3bc (diff) | |
download | chat-5da5c0bbfb80cb5c9cf2699f42d17decc2d60f5b.tar.gz chat-5da5c0bbfb80cb5c9cf2699f42d17decc2d60f5b.tar.bz2 chat-5da5c0bbfb80cb5c9cf2699f42d17decc2d60f5b.zip |
PLT-6987 User access token UI (#7007)
* Add user access token UI
* Fix enter press and update mattermost-redux
* Updating UI for access token stuff (#7066)
* Revert segment key
Diffstat (limited to 'store')
-rw-r--r-- | store/sql_upgrade.go | 6 | ||||
-rw-r--r-- | store/sql_user_store.go | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/store/sql_upgrade.go b/store/sql_upgrade.go index a7b72124e..157a85507 100644 --- a/store/sql_upgrade.go +++ b/store/sql_upgrade.go @@ -282,6 +282,12 @@ func UpgradeDatabaseToVersion40(sqlStore SqlStore) { func UpgradeDatabaseToVersion41(sqlStore SqlStore) { // TODO: Uncomment following condition when version 4.1.0 is released // if shouldPerformUpgrade(sqlStore, VERSION_4_0_0, VERSION_4_1_0) { + + // Increase maximum length of the Users table Roles column. + if sqlStore.GetMaxLengthOfColumnIfExists("Users", "Roles") != "256" { + sqlStore.AlterColumnTypeIfExists("Users", "Roles", "varchar(256)", "varchar(256)") + } + sqlStore.RemoveTableIfExists("JobStatuses") // saveSchemaVersion(sqlStore, VERSION_4_1_0) // } diff --git a/store/sql_user_store.go b/store/sql_user_store.go index ab031ea19..64079c8d3 100644 --- a/store/sql_user_store.go +++ b/store/sql_user_store.go @@ -62,7 +62,7 @@ func NewSqlUserStore(sqlStore SqlStore) UserStore { table.ColMap("Nickname").SetMaxSize(64) table.ColMap("FirstName").SetMaxSize(64) table.ColMap("LastName").SetMaxSize(64) - table.ColMap("Roles").SetMaxSize(64) + table.ColMap("Roles").SetMaxSize(256) table.ColMap("Props").SetMaxSize(4000) table.ColMap("NotifyProps").SetMaxSize(2000) table.ColMap("Locale").SetMaxSize(5) |