sync up leave group from skype
This commit is contained in:
parent
bdab0f6699
commit
261ea31c75
|
@ -1127,7 +1127,7 @@ func (portal *Portal) CreateMatrixRoom(user *User) error {
|
||||||
// content.Users[user.MXID] = 100
|
// content.Users[user.MXID] = 100
|
||||||
//}
|
//}
|
||||||
// When creating a room, make user self the highest level of authority
|
// When creating a room, make user self the highest level of authority
|
||||||
content.Users[user.MXID] = 100
|
content.Users[user.MXID] = 99
|
||||||
initialState := []*event.Event{{
|
initialState := []*event.Event{{
|
||||||
Type: event.StatePowerLevels,
|
Type: event.StatePowerLevels,
|
||||||
Content: event.Content{
|
Content: event.Content{
|
||||||
|
|
|
@ -49,6 +49,7 @@ const (
|
||||||
ChatActionAdd ChatActionType = "add"
|
ChatActionAdd ChatActionType = "add"
|
||||||
ChatActionIntroduce ChatActionType = "introduce"
|
ChatActionIntroduce ChatActionType = "introduce"
|
||||||
ChatActionCreate ChatActionType = "create"
|
ChatActionCreate ChatActionType = "create"
|
||||||
|
ChatActionThread ChatActionType = "Thread"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
8
user.go
8
user.go
|
@ -1087,6 +1087,14 @@ func (user *User) HandleChatUpdate(cmd skype.Resource) {
|
||||||
go portal.membershipAdd(cmd.Content)
|
go portal.membershipAdd(cmd.Content)
|
||||||
case skypeExt.ChatMemberDelete:
|
case skypeExt.ChatMemberDelete:
|
||||||
go portal.membershipRemove(cmd.Content)
|
go portal.membershipRemove(cmd.Content)
|
||||||
|
case "":
|
||||||
|
if skypeExt.ChatActionType(cmd.Type) == skypeExt.ChatActionThread {
|
||||||
|
if len(cmd.ETag) > 0 && len(cmd.Properties.Capabilities) < 1{
|
||||||
|
portal.Delete()
|
||||||
|
portal.Cleanup(false)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//case skypeExt.ChatActionAddTopic:
|
//case skypeExt.ChatActionAddTopic:
|
||||||
// go portal.UpdateTopic(cmd.Data.AddTopic.Topic, cmd.Data.SenderJID)
|
// go portal.UpdateTopic(cmd.Data.AddTopic.Topic, cmd.Data.SenderJID)
|
||||||
//case skypeExt.ChatActionRemoveTopic:
|
//case skypeExt.ChatActionRemoveTopic:
|
||||||
|
|
Loading…
Reference in New Issue