summaryrefslogtreecommitdiffstats
path: root/store/sqlstore/upgrade.go
diff options
context:
space:
mode:
Diffstat (limited to 'store/sqlstore/upgrade.go')
-rw-r--r--store/sqlstore/upgrade.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/store/sqlstore/upgrade.go b/store/sqlstore/upgrade.go
index 2b4532817..174b434f8 100644
--- a/store/sqlstore/upgrade.go
+++ b/store/sqlstore/upgrade.go
@@ -4,6 +4,7 @@
package sqlstore
import (
+ "encoding/json"
"os"
"strings"
"time"
@@ -380,6 +381,12 @@ func UpgradeDatabaseToVersion49(sqlStore SqlStore) {
//TODO: Uncomment the following condition when version 4.9.0 is released
//if shouldPerformUpgrade(sqlStore, VERSION_4_8_0, VERSION_4_9_0) {
sqlStore.CreateColumnIfNotExists("Teams", "LastTeamIconUpdate", "bigint", "bigint", "0")
+ defaultTimezone := model.DefaultUserTimezone()
+ defaultTimezoneValue, err := json.Marshal(defaultTimezone)
+ if err != nil {
+ l4g.Critical(err)
+ }
+ sqlStore.CreateColumnIfNotExists("Users", "Timezone", "varchar(256)", "varchar(256)", string(defaultTimezoneValue))
// saveSchemaVersion(sqlStore, VERSION_4_9_0)
//}
}