From b47534ba870599c1449f3ddccd5c5ae923f2f510 Mon Sep 17 00:00:00 2001 From: 11tuvork28 Date: Sun, 4 Feb 2024 12:58:16 +0100 Subject: [PATCH] Add auth to endpoint --- backend/src/guild/guild.controller.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/src/guild/guild.controller.ts b/backend/src/guild/guild.controller.ts index ca6dfe7..d2ae2a4 100644 --- a/backend/src/guild/guild.controller.ts +++ b/backend/src/guild/guild.controller.ts @@ -1,9 +1,11 @@ -import { Controller, Get, Inject, Param } from '@nestjs/common'; +import { Controller, Get, Inject, Param, UseGuards } from '@nestjs/common'; import { GuildService } from './guild.service'; import { InjectDiscordClient } from '@discord-nestjs/core'; import { Client } from 'discord.js'; +import { JwtAuthGuard } from 'src/auth/jwt/guards/jwt-auth.guard'; @Controller('/') +@UseGuards(JwtAuthGuard) export class GuildController { constructor( @Inject(GuildService) private guildService: GuildService,