implement new invitation system

* fix comments on the frontend
* move jwt token service to its own module
* other fixes and updates
This commit is contained in:
Philipinho
2024-05-14 22:55:11 +01:00
parent 525990d6e5
commit eefe63d1cd
75 changed files with 10965 additions and 7846 deletions

View File

@ -66,8 +66,7 @@ export class CommentService {
workspaceId: workspaceId,
});
// return created comment and creator relation
return this.findById(createdComment.id);
return createdComment;
}
async findByPageId(
@ -114,7 +113,12 @@ export class CommentService {
return comment;
}
async remove(id: string): Promise<void> {
await this.commentRepo.deleteComment(id);
async remove(commentId: string): Promise<void> {
const comment = await this.commentRepo.findById(commentId);
if (!comment) {
throw new NotFoundException('Comment not found');
}
await this.commentRepo.deleteComment(commentId);
}
}