Skip to content

Commit 9c084f0

Browse files
committed
Merge branch 'main' of github.com:izadoesdev/mono
2 parents 34ef933 + 9704c69 commit 9c084f0

1 file changed

Lines changed: 0 additions & 10 deletions

File tree

apps/api/src/routes/v1/websites.ts

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -256,16 +256,6 @@ websitesRouter.get('/', async (c) => {
256256
return c.json({ success: false, error: "Unauthorized" }, 401);
257257
}
258258

259-
if (user.role === 'ADMIN') {
260-
const allWebsites = await db.query.websites.findMany({
261-
orderBy: (websites, { desc }) => [desc(websites.createdAt)]
262-
});
263-
return c.json({
264-
success: true,
265-
data: allWebsites
266-
});
267-
}
268-
269259
try {
270260
const userWebsites = await db.query.websites.findMany({
271261
where: eq(websites.userId, user.id),

0 commit comments

Comments
 (0)