Diary fix

This commit is contained in:
Torsten Schulz
2025-03-17 23:42:22 +01:00
parent c294dd7b2a
commit f935c72f56
2 changed files with 45 additions and 33 deletions

View File

@@ -8,8 +8,7 @@ class AccidentService {
await checkAccess(userToken, clubId);
const user = await getUserByToken(userToken);
if (!user) {
console.log('---------------');
throw new Error('User not found');
throw new Error('User not found');
}
const member = await Member.findByPk(memberId);
if (!member || member.clubId != clubId) {