diff --git a/controller/api.js b/controller/api.js index b94c3b3..b90bd2b 100644 --- a/controller/api.js +++ b/controller/api.js @@ -81,8 +81,9 @@ exports.guildUpdate = (bot)=> var aux = {} aux[req.params.setting] = !original[req.params.setting] const updated = await GuildM.findOneAndUpdate({gID:req.params.id}, aux) + const userid = await new DiscordAPI(req.headers.cookie, bot).getUserId(); const guild = await new DiscordAPI(req.headers.cookie, bot).getSpecificGuildDataForDash(req.params.id); - res.render('guildPopup.ejs', {guild}) + res.render('guildPopup.ejs', {guild,userid}) } }