summaryrefslogtreecommitdiffstats
path: root/model/channel.go
diff options
context:
space:
mode:
authorJesse Hallam <jesse.hallam@gmail.com>2018-05-23 10:28:19 -0400
committerGitHub <noreply@github.com>2018-05-23 10:28:19 -0400
commit0a666a56560713a084847ce683b940c1aa84acc0 (patch)
tree016b05400fe0b5a1fc5d0300a376f9502992bb2c /model/channel.go
parent70a118c0fd45f8ab2510c80a0110f24be21f8785 (diff)
downloadchat-0a666a56560713a084847ce683b940c1aa84acc0.tar.gz
chat-0a666a56560713a084847ce683b940c1aa84acc0.tar.bz2
chat-0a666a56560713a084847ce683b940c1aa84acc0.zip
MM-10649: soften Channels.ExtraUpdateAt deprecation (#8843)
The previous complete removal of this field resulted in an incompatibility with 4.x servers that could not handle the now null column field. Instead, ensure this field is at least always set to 0, with a plan to remove it altogether in a future release.
Diffstat (limited to 'model/channel.go')
-rw-r--r--model/channel.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/model/channel.go b/model/channel.go
index 749b8dc94..950e910dd 100644
--- a/model/channel.go
+++ b/model/channel.go
@@ -44,6 +44,7 @@ type Channel struct {
Purpose string `json:"purpose"`
LastPostAt int64 `json:"last_post_at"`
TotalMsgCount int64 `json:"total_msg_count"`
+ ExtraUpdateAt int64 `json:"extra_update_at"`
CreatorId string `json:"creator_id"`
}
@@ -132,6 +133,7 @@ func (o *Channel) PreSave() {
o.CreateAt = GetMillis()
o.UpdateAt = o.CreateAt
+ o.ExtraUpdateAt = 0
}
func (o *Channel) PreUpdate() {