summary refs log tree commit diff
path: root/api
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-10-14 19:46:53 +0200
committerFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-10-14 19:46:53 +0200
commit88edaba3ab1f2c5666743a517a5bcd5c9b864c58 (patch)
treecb18c2da34293ed5f52a52856b4a81e7eaa5b79b /api
parent:sparkles: stickers (diff)
downloadserver-88edaba3ab1f2c5666743a517a5bcd5c9b864c58.tar.xz
:sparkles: sticker packs
Diffstat (limited to 'api')
-rw-r--r--api/src/routes/sticker-packs/#id/index.ts19
-rw-r--r--api/src/routes/sticker-packs/index.ts4
2 files changed, 2 insertions, 21 deletions
diff --git a/api/src/routes/sticker-packs/#id/index.ts b/api/src/routes/sticker-packs/#id/index.ts
deleted file mode 100644
index 7f723e97..00000000
--- a/api/src/routes/sticker-packs/#id/index.ts
+++ /dev/null
@@ -1,19 +0,0 @@
-import { Request, Response, Router } from "express";
-import { route } from "@fosscord/api";
-
-const router: Router = Router();
-
-router.get("/", route({}), async (req: Request, res: Response) => {
-	//TODO
-	res.json({
-		id: "",
-		stickers: [],
-		name: "",
-		sku_id: "",
-		cover_sticker_id: "",
-		description: "",
-		banner_asset_id: ""
-	}).status(200);
-});
-
-export default router;
diff --git a/api/src/routes/sticker-packs/index.ts b/api/src/routes/sticker-packs/index.ts
index d671c161..89b91bdb 100644
--- a/api/src/routes/sticker-packs/index.ts
+++ b/api/src/routes/sticker-packs/index.ts
@@ -1,11 +1,11 @@
 import { Request, Response, Router } from "express";
 import { route } from "@fosscord/api";
+import { StickerPack } from "@fosscord/util/src/entities/StickerPack";
 
 const router: Router = Router();
 
 router.get("/", route({}), async (req: Request, res: Response) => {
-	//TODO
-	res.json({ sticker_packs: [] }).status(200);
+	res.json(await StickerPack.find({}));
 });
 
 export default router;