fix: resolve ESLint errors — remove unused imports and dead code

This commit is contained in:
Ryan Moon
2026-04-01 20:18:13 -05:00
parent c3de66e554
commit 0f8aff9426
9 changed files with 7 additions and 28 deletions

View File

@@ -115,7 +115,6 @@ export const storageRoutes: FastifyPluginAsync = async (app) => {
app.delete('/storage/folder-permissions/:id', { preHandler: [app.authenticate, app.requirePermission('files.delete')] }, async (request, reply) => {
const { id } = request.params as { id: string }
// Look up the permission to find which folder it belongs to
const existing = await StoragePermissionService.listPermissions(app.db, id)
// listPermissions takes folderId, we need to find by perm id — use removePermission which fetches first
const perm = await StoragePermissionService.getPermissionById(app.db, id)
if (!perm) return reply.status(404).send({ error: { message: 'Permission not found', statusCode: 404 } })