Skip to content
Snippets Groups Projects

Json validation

Merged Ghost User requested to merge json-validation into Development
2 files
+ 11
0
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -17,6 +17,7 @@ import { User } from '../user/user.decorator';
import { GameDTO, FlagboxEventDTO } from './game.dto';
import { ValidationPipe } from '../shared/validation.pipe';
import { Roles } from '../shared/roles.decorator';
import { GameEntity } from './game.entity';
@Controller('game')
export class GameController {
@@ -48,6 +49,12 @@ export class GameController {
return this.gameservice.returnGameInfo(id);
}
@Get('get-factions/:id')
@Roles('admin')
async returnGameFactions(@Param('id') id: GameEntity) {
return this.gameservice.listFactions(id);
}
@Get('flag/:id')
async flagboxQuery(@Param('id') id: string) {
return this.gameservice.flagboxQuery(id);
Loading