aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDanail Dimitrov <danaildimitrov321@gmail.com>2021-01-28 22:31:55 +0200
committerDanail Dimitrov <danaildimitrov321@gmail.com>2021-01-28 22:31:55 +0200
commit9ceef59cb170640cb7cff643de7efd19ad8a48e9 (patch)
tree10ea1d23cc50f96ca11e6eb5c2c0c9ec88179de2 /src
parent40bf9980b707232019439313af30e586e8105fed (diff)
parent52c7f1f735e6846535dd58b08dc1ff8255a65a81 (diff)
downloadDevHive-9ceef59cb170640cb7cff643de7efd19ad8a48e9.tar
DevHive-9ceef59cb170640cb7cff643de7efd19ad8a48e9.tar.gz
DevHive-9ceef59cb170640cb7cff643de7efd19ad8a48e9.zip
Merge branch 'dev' of https://github.com/Team-Kaleidoscope/DevHive into dev
Diffstat (limited to 'src')
-rw-r--r--src/DevHive.Web/Controllers/PostController.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/DevHive.Web/Controllers/PostController.cs b/src/DevHive.Web/Controllers/PostController.cs
index 0ca041f..fe71519 100644
--- a/src/DevHive.Web/Controllers/PostController.cs
+++ b/src/DevHive.Web/Controllers/PostController.cs
@@ -29,7 +29,7 @@ namespace DevHive.Web.Controllers
[HttpPost]
public async Task<IActionResult> Create(Guid userId, [FromBody] CreatePostWebModel createPostWebModel, [FromHeader] string authorization)
{
- if (await this._postService.ValidateJwtForCreating(userId, authorization))
+ if (!await this._postService.ValidateJwtForCreating(userId, authorization))
return new UnauthorizedResult();
CreatePostServiceModel createPostServiceModel =
@@ -47,7 +47,7 @@ namespace DevHive.Web.Controllers
[Route("Comment")]
public async Task<IActionResult> AddComment(Guid userId, [FromBody] CreateCommentWebModel createCommentWebModel, [FromHeader] string authorization)
{
- if (await this._postService.ValidateJwtForCreating(userId, authorization))
+ if (!await this._postService.ValidateJwtForCreating(userId, authorization))
return new UnauthorizedResult();
CreateCommentServiceModel createCommentServiceModel =