Pass invites to the receive object

This commit passes a room invite to the receive node, so you can react to it.

Sample invitation:

HDsvcHGiTYFxxxxxxx:mydomain.de : msg : Object
object
type: "r.invite"
payload: "Invitation"
userId: "@relay:mydomain.de"
topic: "!HDsvcHGiTYFxxxxxxx:mydomain.de"
_msgid: "ef1fd7f3c8ae82e6"
This commit is contained in:
Marco Jakobs
2022-11-25 20:56:06 +01:00
parent 4c17a21008
commit 908d60835d
2 changed files with 13 additions and 0 deletions
+7
View File
@@ -239,6 +239,13 @@ module.exports = function(RED) {
});
} else {
node.log("Got invite to join room " + member.roomId);
let msg = {
type : 'r.invite',
payload : 'Invitation',
userId : member.userId,
topic : member.roomId
};
node.emit("Room.invite", msg);
}
}
});