-
Notifications
You must be signed in to change notification settings - Fork 23
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
contactAvatar 方法为什么调用的是 grpc 的 contactSelfQRCode?
public async contactAvatar (contactId: string, fileBox?: FileBox): Promise<void | FileBox> {
log.verbose('PuppetHostie', 'contactAvatar(%s)', contactId)
/**
* 1. set
*/
if (fileBox) {
const fileboxWrapper = new StringValue()
fileboxWrapper.setValue(JSON.stringify(fileBox))
const request = new ContactAvatarRequest()
request.setId(contactId)
request.setFilebox(fileboxWrapper)
await util.promisify(
this.grpcClient!.contactSelfQRCode.bind(this.grpcClient)
)(request)
return
}
/**
* 2. get
*/
const request = new ContactAvatarRequest()
request.setId(contactId)
const response = await util.promisify(
this.grpcClient!.contactSelfQRCode.bind(this.grpcClient)
)(request)
const qrcode = response.getQrcode()
return FileBox.fromQRCode(qrcode)
}Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working