Closed suntong closed 3 years ago
Can you provide some detail info about this problem with log here?
Thank you.
const sender: Contact | null = msg.from() if (sender.type() === Contact.Type.Official) { log.info('onMessage', 'todo 暂不处理公众号消息') return }
Wow, works like a charm. Thanks a lot @guoxiangke!
FTR,
Contact.Type
: ContactType.Unknown | ContactType.Personal | ContactType.Official
Ref: https://wechaty.js.org/docs/api/contact#Contact
Not that straightforward to me, i.e., it'd take me quite a while to translate above into actual code.
Is your feature request related to a problem? Please describe.
请问,padplus如何判断公众号的文章推送啊? 我一直用的方法在昨天突然不管用了
A clear and concise description of what the problem is.
I always filter out the 公众号的文章推送, but suddenly they become url type several days ago.
Describe the solution you'd like
公众号的文章推送 are indeed url type, but please make it distinguishable from the normal url type. I.e., they are from 公众号, that's the most prominent identification.
[enhancement]