summaryrefslogtreecommitdiffstats
path: root/vendor/go.mau.fi/whatsmeow/user.go
diff options
context:
space:
mode:
authorWim <wim@42.be>2022-06-11 23:07:42 +0200
committerGitHub <noreply@github.com>2022-06-11 23:07:42 +0200
commit8751fb4bb1eb7cd34ed63be9b3801b8aeac71a1d (patch)
tree601d2616b05b5b197bd2a3ae7cb245b1a0ea17e7 /vendor/go.mau.fi/whatsmeow/user.go
parent3819062574ac7e4af6a562bf40a425469a7752fb (diff)
downloadmatterbridge-msglm-8751fb4bb1eb7cd34ed63be9b3801b8aeac71a1d.tar.gz
matterbridge-msglm-8751fb4bb1eb7cd34ed63be9b3801b8aeac71a1d.tar.bz2
matterbridge-msglm-8751fb4bb1eb7cd34ed63be9b3801b8aeac71a1d.zip
Update dependencies (#1841)
Diffstat (limited to 'vendor/go.mau.fi/whatsmeow/user.go')
-rw-r--r--vendor/go.mau.fi/whatsmeow/user.go13
1 files changed, 5 insertions, 8 deletions
diff --git a/vendor/go.mau.fi/whatsmeow/user.go b/vendor/go.mau.fi/whatsmeow/user.go
index fea80521..bbddd405 100644
--- a/vendor/go.mau.fi/whatsmeow/user.go
+++ b/vendor/go.mau.fi/whatsmeow/user.go
@@ -123,22 +123,19 @@ func (cli *Client) GetUserInfo(jids []types.JID) (map[types.JID]types.UserInfo,
if child.Tag != "user" || !jidOK {
continue
}
+ var info types.UserInfo
verifiedName, err := parseVerifiedName(child.GetChildByTag("business"))
if err != nil {
cli.Log.Warnf("Failed to parse %s's verified name details: %v", jid, err)
}
status, _ := child.GetChildByTag("status").Content.([]byte)
- pictureID, _ := child.GetChildByTag("picture").Attrs["id"].(string)
- devices := parseDeviceList(jid.User, child.GetChildByTag("devices"))
- respData[jid] = types.UserInfo{
- VerifiedName: verifiedName,
- Status: string(status),
- PictureID: pictureID,
- Devices: devices,
- }
+ info.Status = string(status)
+ info.PictureID, _ = child.GetChildByTag("picture").Attrs["id"].(string)
+ info.Devices = parseDeviceList(jid.User, child.GetChildByTag("devices"))
if verifiedName != nil {
cli.updateBusinessName(jid, verifiedName.Details.GetVerifiedName())
}
+ respData[jid] = info
}
return respData, nil
}