Closed su-chang closed 2 years ago
If you remove the MemoryCard support from a puppet, then you will not be able to restore sessions from the Wechaty framework in the future.
If you remove the MemoryCard support from a puppet, then you will not be able to restore sessions from the Wechaty framework in the future.
I will think about how to use MemoryCard to store LocalAuth session.
For example, use MemoryCard store the LocalAuth clientId
from Wechaty framework.
this.whatsAppClient = new WhatsApp({
authStrategy: new LocalAuth({ clientId: 'default-client' }),
...
})
Using MemoryCard with Wechaty/Puppet is quite easy and straightforward:
this.memory.set('clientId', clientId)
await this.memory.save()
Then it will be enough.
Using it:
const clientId = await this.memory.get('clientId')
Thank you for your suggestion, and MemoryCard will be back later in this pr.
Great to know MemoryCard will be back later in this pr, and you are welcome!
@huan MemoryCard back now, and do you have some other suggestions for this pr?
Great to see that, I have no more suggestions, thank you very much.
Related issue: https://github.com/pedroslopez/whatsapp-web.js/pull/1257