fix(api): remove unused 'deleted' variable in staff DELETE handler

The transaction callback returns [guardError, deleted] but only
guardError is consumed. Destructure only what we need.

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
Flea Flicker
2026-03-29 12:20:37 +00:00
parent c76a37b15c
commit 8c154e82f4
+1 -1
View File
@@ -158,7 +158,7 @@ staffRouter.delete("/:id", async (c) => {
}
// Prevent deleting the last super user — use transaction to avoid race
const [guardError, deleted] = await db.transaction(async (tx) => {
const [guardError] = await db.transaction(async (tx) => {
const [targetStaff] = await tx
.select({ isSuperUser: staff.isSuperUser })
.from(staff)