Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
type = MessageType.Audio
// console.log(rawPayload)
break
case PadplusMessageType.Emoticon:
type = MessageType.Emoticon
// console.log(rawPayload)
break
case PadplusMessageType.App:
type = MessageType.Attachment
// console.log(rawPayload)
break
case PadplusMessageType.Location:
type = MessageType.Location
// console.log(rawPayload)
break
case PadplusMessageType.Video:
type = MessageType.Video
// console.log(rawPayload)
break
case PadplusMessageType.Sys:
type = MessageType.Unknown
break
case PadplusMessageType.ShareCard:
type = MessageType.Contact
break
payload.type = MessageType.Attachment
payload.filename = appPayload.title
break
case WechatAppMessageType.ChatHistory:
payload.type = MessageType.ChatHistory
break
case WechatAppMessageType.MiniProgram:
case WechatAppMessageType.MiniProgramApp:
payload.type = MessageType.MiniProgram
break
case WechatAppMessageType.RedEnvelopes:
case WechatAppMessageType.Transfers:
payload.type = MessageType.Money
break
case WechatAppMessageType.RealtimeShareLocation:
payload.type = MessageType.Location
break
default:
payload.type = MessageType.Unknown
break
}
}
}
return payload
}