diff options
author | Wim <wim@42.be> | 2023-08-05 20:43:19 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-05 20:43:19 +0200 |
commit | 56e7bd01ca09ad52b0c4f48f146a20a4f1b78696 (patch) | |
tree | b1355645342667209263cbd355dc0b4254f1e8fe /vendor/go.mau.fi/whatsmeow/group.go | |
parent | 9459495484d6e06a3d46de64fccd8d06f7ccc72c (diff) | |
download | matterbridge-msglm-56e7bd01ca09ad52b0c4f48f146a20a4f1b78696.tar.gz matterbridge-msglm-56e7bd01ca09ad52b0c4f48f146a20a4f1b78696.tar.bz2 matterbridge-msglm-56e7bd01ca09ad52b0c4f48f146a20a4f1b78696.zip |
Diffstat (limited to 'vendor/go.mau.fi/whatsmeow/group.go')
-rw-r--r-- | vendor/go.mau.fi/whatsmeow/group.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/vendor/go.mau.fi/whatsmeow/group.go b/vendor/go.mau.fi/whatsmeow/group.go index c771b5a2..c8f80560 100644 --- a/vendor/go.mau.fi/whatsmeow/group.go +++ b/vendor/go.mau.fi/whatsmeow/group.go @@ -57,7 +57,7 @@ func (cli *Client) CreateGroup(req ReqCreateGroup) (*types.GroupInfo, error) { } } if req.CreateKey == "" { - req.CreateKey = GenerateMessageID() + req.CreateKey = cli.GenerateMessageID() } if req.IsParent { if req.DefaultMembershipApprovalMode == "" { @@ -99,7 +99,7 @@ func (cli *Client) CreateGroup(req ReqCreateGroup) (*types.GroupInfo, error) { func (cli *Client) UnlinkGroup(parent, child types.JID) error { _, err := cli.sendGroupIQ(context.TODO(), iqSet, parent, waBinary.Node{ Tag: "unlink", - Attrs: waBinary.Attrs{"unlink_type": types.GroupLinkChangeTypeSub}, + Attrs: waBinary.Attrs{"unlink_type": string(types.GroupLinkChangeTypeSub)}, Content: []waBinary.Node{{ Tag: "group", Attrs: waBinary.Attrs{"jid": child}, @@ -116,7 +116,7 @@ func (cli *Client) LinkGroup(parent, child types.JID) error { Tag: "links", Content: []waBinary.Node{{ Tag: "link", - Attrs: waBinary.Attrs{"link_type": types.GroupLinkChangeTypeSub}, + Attrs: waBinary.Attrs{"link_type": string(types.GroupLinkChangeTypeSub)}, Content: []waBinary.Node{{ Tag: "group", Attrs: waBinary.Attrs{"jid": child}, @@ -221,7 +221,7 @@ func (cli *Client) SetGroupName(jid types.JID, name string) error { // // The previousID and newID fields are optional. If the previous ID is not specified, this will // automatically fetch the current group info to find the previous topic ID. If the new ID is not -// specified, one will be generated with GenerateMessageID(). +// specified, one will be generated with Client.GenerateMessageID(). func (cli *Client) SetGroupTopic(jid types.JID, previousID, newID, topic string) error { if previousID == "" { oldInfo, err := cli.GetGroupInfo(jid) @@ -231,7 +231,7 @@ func (cli *Client) SetGroupTopic(jid types.JID, previousID, newID, topic string) previousID = oldInfo.TopicID } if newID == "" { - newID = GenerateMessageID() + newID = cli.GenerateMessageID() } attrs := waBinary.Attrs{ "id": newID, |