fix: clean up decorators in the public notes.controller.ts

Signed-off-by: Yannick Bungers <git@innay.de>
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
Yannick Bungers 2023-03-25 16:31:48 +01:00 committed by Yannick Bungers
parent d369132519
commit 0f464dedfe

View file

@ -101,7 +101,6 @@ export class NotesController {
} }
@Permissions(Permission.CREATE) @Permissions(Permission.CREATE)
@UseGuards(PermissionsGuard)
@Post(':noteAlias') @Post(':noteAlias')
@OpenApi( @OpenApi(
{ {
@ -233,7 +232,6 @@ export class NotesController {
@UseInterceptors(GetNoteInterceptor) @UseInterceptors(GetNoteInterceptor)
@Permissions(Permission.READ) @Permissions(Permission.READ)
@UseGuards(TokenAuthGuard, PermissionsGuard)
@Get(':noteIdOrAlias/metadata/permissions') @Get(':noteIdOrAlias/metadata/permissions')
@OpenApi( @OpenApi(
{ {
@ -253,7 +251,6 @@ export class NotesController {
@UseInterceptors(GetNoteInterceptor) @UseInterceptors(GetNoteInterceptor)
@Permissions(Permission.OWNER) @Permissions(Permission.OWNER)
@UseGuards(TokenAuthGuard, PermissionsGuard)
@Put(':noteIdOrAlias/metadata/permissions/users/:userName') @Put(':noteIdOrAlias/metadata/permissions/users/:userName')
@OpenApi( @OpenApi(
{ {
@ -281,7 +278,6 @@ export class NotesController {
@UseInterceptors(GetNoteInterceptor) @UseInterceptors(GetNoteInterceptor)
@Permissions(Permission.OWNER) @Permissions(Permission.OWNER)
@UseGuards(TokenAuthGuard, PermissionsGuard)
@Delete(':noteIdOrAlias/metadata/permissions/users/:userName') @Delete(':noteIdOrAlias/metadata/permissions/users/:userName')
@OpenApi( @OpenApi(
{ {
@ -316,7 +312,6 @@ export class NotesController {
@UseInterceptors(GetNoteInterceptor) @UseInterceptors(GetNoteInterceptor)
@Permissions(Permission.OWNER) @Permissions(Permission.OWNER)
@UseGuards(TokenAuthGuard, PermissionsGuard)
@Put(':noteIdOrAlias/metadata/permissions/groups/:groupName') @Put(':noteIdOrAlias/metadata/permissions/groups/:groupName')
@OpenApi( @OpenApi(
{ {
@ -344,7 +339,6 @@ export class NotesController {
@UseInterceptors(GetNoteInterceptor) @UseInterceptors(GetNoteInterceptor)
@Permissions(Permission.OWNER) @Permissions(Permission.OWNER)
@UseGuards(TokenAuthGuard, PermissionsGuard)
@Delete(':noteIdOrAlias/metadata/permissions/groups/:groupName') @Delete(':noteIdOrAlias/metadata/permissions/groups/:groupName')
@OpenApi( @OpenApi(
{ {
@ -370,7 +364,6 @@ export class NotesController {
@UseInterceptors(GetNoteInterceptor) @UseInterceptors(GetNoteInterceptor)
@Permissions(Permission.OWNER) @Permissions(Permission.OWNER)
@UseGuards(TokenAuthGuard, PermissionsGuard)
@Put(':noteIdOrAlias/metadata/permissions/owner') @Put(':noteIdOrAlias/metadata/permissions/owner')
@OpenApi( @OpenApi(
{ {