feat: room photo gallery, featured photo, and comments moderation

This commit is contained in:
2026-06-27 19:25:00 -05:00
parent 7cc1877674
commit a11bd3ada8
10 changed files with 583 additions and 69 deletions
+5
View File
@@ -71,3 +71,8 @@ export async function requireAuth() {
}
return session;
}
export async function canComment(userId: number) {
const { rows } = await db.query('SELECT comments_disabled FROM users WHERE id = $1', [userId]);
return rows.length === 0 || !rows[0].comments_disabled;
}