1
0
mirror of https://github.com/spacebarchat/server.git synced 2024-11-11 05:02:37 +01:00

🐛 fix bans

This commit is contained in:
Flam3rboy 2021-08-10 01:48:56 +02:00
parent 96c55f6c6c
commit b4e973c3ca
3 changed files with 9 additions and 9 deletions

14
package-lock.json generated
View File

@ -9,7 +9,7 @@
"version": "1.0.0",
"license": "ISC",
"dependencies": {
"@fosscord/server-util": "^1.3.45",
"@fosscord/server-util": "^1.3.46",
"@types/jest": "^26.0.22",
"@types/json-schema": "^7.0.7",
"ajv": "^8.4.0",
@ -678,9 +678,9 @@
}
},
"node_modules/@fosscord/server-util": {
"version": "1.3.45",
"resolved": "https://registry.npmjs.org/@fosscord/server-util/-/server-util-1.3.45.tgz",
"integrity": "sha512-0IlapIxDOBlU5CtMgTyr6Pc8e+MLqvrcpxFz6Ql+t+bJJkOfTpCR2fk8qSKoDiNijR/S1gHO87vcIvHN/WL98Q==",
"version": "1.3.46",
"resolved": "https://registry.npmjs.org/@fosscord/server-util/-/server-util-1.3.46.tgz",
"integrity": "sha512-YX2pSkgsxrFcdEVXQWuQYHmT+P0Y+BtGRopZf5HKeHbjDl4/Bblj/GRU55qvtHsW5/6XQBZCG/GoeTu/MMQ+xw==",
"dependencies": {
"@types/jsonwebtoken": "^8.5.0",
"@types/mongoose-autopopulate": "^0.10.1",
@ -11457,9 +11457,9 @@
}
},
"@fosscord/server-util": {
"version": "1.3.45",
"resolved": "https://registry.npmjs.org/@fosscord/server-util/-/server-util-1.3.45.tgz",
"integrity": "sha512-0IlapIxDOBlU5CtMgTyr6Pc8e+MLqvrcpxFz6Ql+t+bJJkOfTpCR2fk8qSKoDiNijR/S1gHO87vcIvHN/WL98Q==",
"version": "1.3.46",
"resolved": "https://registry.npmjs.org/@fosscord/server-util/-/server-util-1.3.46.tgz",
"integrity": "sha512-YX2pSkgsxrFcdEVXQWuQYHmT+P0Y+BtGRopZf5HKeHbjDl4/Bblj/GRU55qvtHsW5/6XQBZCG/GoeTu/MMQ+xw==",
"requires": {
"@types/jsonwebtoken": "^8.5.0",
"@types/mongoose-autopopulate": "^0.10.1",

View File

@ -33,7 +33,7 @@
},
"homepage": "https://github.com/fosscord/fosscord-api#readme",
"dependencies": {
"@fosscord/server-util": "^1.3.45",
"@fosscord/server-util": "^1.3.46",
"@types/jest": "^26.0.22",
"@types/json-schema": "^7.0.7",
"ajv": "^8.4.0",

View File

@ -16,7 +16,7 @@ router.get("/", async (req: Request, res: Response) => {
const guild = await GuildModel.exists({ id: guild_id });
if (!guild) throw new HTTPError("Guild not found", 404);
var bans = await BanModel.find({ guild_id: guild_id }, { user: true, reason: true }).exec();
var bans = await BanModel.find({ guild_id: guild_id }, { user_id: true, reason: true }).exec();
return res.json(toObject(bans));
});