Show text received

This commit is contained in:
Oskar Thoren 2020-10-19 13:19:46 +08:00
parent 4cc4ee961a
commit 06bf3de806
No known key found for this signature in database
GPG Key ID: B2ECCFD3BC2EF77E
1 changed files with 6 additions and 0 deletions

View File

@ -107,7 +107,13 @@ class Chat extends EventEmitter {
// XXX: Might not always work...
const text = String.fromCharCode(...msg.payload)
console.info("WakuMessage: ", msg.contentTopic, text)
this.emit('message', {
from: "Unknown",
data: text
})
}
else {
//TODO Figure out how to re-enable / remove wrt chat2 example
const request = Request.decode(message.data)