Refactoring direct channel creation to use transaction to avaoid state where channel is created without both users

Этот коммит содержится в:
Christopher Speller
2015-10-22 09:31:27 -04:00
родитель e0cda76eb8
Коммит 6cc3bfe7a9
4 изменённых файлов: 261 добавлений и 69 удалений

Просмотреть файл

@@ -54,6 +54,7 @@ type TeamStore interface {
type ChannelStore interface {
Save(channel *model.Channel) StoreChannel
SaveDirectChannel(channel *model.Channel, member1 *model.ChannelMember, member2 *model.ChannelMember) StoreChannel
Update(channel *model.Channel) StoreChannel
Get(id string) StoreChannel
Delete(channelId string, time int64) StoreChannel