mirror of
https://github.com/FranP-code/Baileys.git
synced 2025-10-13 00:32:22 +00:00
fix: delivery receipt
This commit is contained in:
@@ -13,7 +13,13 @@ const STATUS_MAP: { [_: string]: proto.WebMessageInfo.WebMessageInfoStatus } = {
|
|||||||
'read-self': proto.WebMessageInfo.WebMessageInfoStatus.READ
|
'read-self': proto.WebMessageInfo.WebMessageInfoStatus.READ
|
||||||
}
|
}
|
||||||
|
|
||||||
const getStatusFromReceiptType = (type: string | undefined) => STATUS_MAP[type]
|
const getStatusFromReceiptType = (type: string | undefined) => {
|
||||||
|
const status = STATUS_MAP[type]
|
||||||
|
if(typeof type === 'undefined') {
|
||||||
|
return proto.WebMessageInfo.WebMessageInfoStatus.DELIVERY_ACK
|
||||||
|
}
|
||||||
|
return status
|
||||||
|
}
|
||||||
|
|
||||||
export const makeMessagesRecvSocket = (config: SocketConfig) => {
|
export const makeMessagesRecvSocket = (config: SocketConfig) => {
|
||||||
const { logger } = config
|
const { logger } = config
|
||||||
|
|||||||
Reference in New Issue
Block a user