v1.6.0/added support, cleanup webhook

This commit is contained in:
2020-08-02 20:41:52 -04:00
parent 86ee168045
commit e388dbf283
14 changed files with 247 additions and 72 deletions
+3 -1
View File
@@ -32,7 +32,8 @@ module.exports = async (req, res) => {
.then((userSnap) => userSnap.exists);
if (userExists) {
if (showChanged === true && player.showName) {
await admin
if (player.showChanged !== roomData.player.showName) {
await admin
.firestore()
.collection('rooms')
.doc(roomId)
@@ -43,6 +44,7 @@ module.exports = async (req, res) => {
text: `${userName} changed \n${player.showName ? 'to ' + player.showName : ''}`,
time: new Date(),
});
}
}
if (roomData.status !== player.status) {
await admin