Skip to content

Commit d70ca4a

Browse files
OOS Patch
Co-authored-by: israel.aristide <israel.aristide@plusgrade.com>
1 parent 39ecdf0 commit d70ca4a

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

src/api/v1/controllers/DiscordControllers.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ async function GetGuild(req, res) {
9292

9393
const id = req.params.id;
9494
const guildschemas = await Guild.find();
95-
const guildData = guildschemas.filter(x => x.guildsnowflake === id)[0]
95+
const guildData = guildschemas.filter(x => x.guildsnowflake.toString() === id)[0]
9696

9797
// Guard if the userid is undefined
9898
if (id === undefined)

src/auth/v2/middlewares/whitelist.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ module.exports = (auth = 'v2') => {
1717
}
1818

1919
const guilds = await Guild.find();
20-
const guild = guilds.filter(x => x.guildsnowflake === id)
20+
const guild = guilds.filter(x => x.guildsnowflake.toSting() === id)
2121

2222
if (guild.length === 0) {
2323
res.status(404).json({

0 commit comments

Comments
 (0)