Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
fabian4 committed Mar 31, 2022
1 parent 8fdd0f2 commit 90559a6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/puppet-walnut.ts
Original file line number Diff line number Diff line change
Expand Up @@ -181,11 +181,11 @@ class PuppetWalnut extends PUPPET.Puppet {
*/
override async messageRawPayloadParser (rawPayload: WalnutMessagePayload): Promise<PUPPET.payloads.Message> {
const res = {
fromId: rawPayload.senderAddress.replace('tel:+86', ''),
id: rawPayload.messageId,
listenerId: rawPayload.destinationAddress,
talkerId: rawPayload.senderAddress.replace('tel:+86', ''),
text: rawPayload.messageList[0]!.contentText.toString(),
timestamp: Date.parse(rawPayload.dateTime),
toId: rawPayload.destinationAddress,
type: PUPPET.types.Message.Text,
}
const file = rawPayload.messageList[0]?.contentText[0] as FileItem
Expand Down

0 comments on commit 90559a6

Please sign in to comment.