Self service registration feature/112-selfservice_registration #120

Merged
niggl merged 31 commits from feature/112-selfservice_registration into dev 2021-01-22 14:13:29 +00:00
Showing only changes of commit 6469e3bc97 - Show all commits

View File

@ -48,7 +48,8 @@ export class CreateSelfServiceRunner extends CreateParticipant {
return group; return group;
} }
const team = await getConnection().getRepository(RunnerTeam).findOne({ id: this.team }, { relations: ["parentGroup"] }); const team = await getConnection().getRepository(RunnerTeam).findOne({ id: this.team }, { relations: ["parentGroup"] });
if (team.parentGroup.id != group.id || !team) { throw new RunnerTeamNotFoundError(); } if (!team) { throw new RunnerTeamNotFoundError(); }
if (team.parentGroup.id != group.id) { throw new RunnerTeamNotFoundError(); }
return team; return team;
} }
} }