From 77695ac8f48b905607fcaf3046c2a36e1773998a Mon Sep 17 00:00:00 2001 From: Pierre HUBERT Date: Sat, 21 Mar 2020 11:51:51 +0100 Subject: [PATCH] Can get information about a single comment --- src/controllers/CommentsController.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/controllers/CommentsController.ts b/src/controllers/CommentsController.ts index cbf465c..9b337b7 100644 --- a/src/controllers/CommentsController.ts +++ b/src/controllers/CommentsController.ts @@ -56,9 +56,10 @@ export class CommentsController { * @param h Request handler */ public static async GetSingle(h: RequestHandler) { - const commentID = h.postCommentIDWithAccess("commentID"); + const commentID = await h.postCommentIDWithAccess("commentID"); + const comment = await CommentsHelper.GetSingle(commentID); - console.log("Comment ID: " + commentID); + h.send(await this.CommentToAPI(h, comment)) } /**