public bool LikeComment(User user, string commentId) { try { _likesRepository.LikeComment(user.UserId, commentId); } catch (Exception e) { _log.Error(e); return(false); } string reciverId = _usersRepository.GetCommentPublish(commentId).UserId; if (user.UserId != reciverId) { object obj = new { commentId, user, postId = _postsRepository.GetPostIdByCommentId(commentId), ReciverId = reciverId }; _serverComunication.NotifyUser("/UserLikeComment", obj); } return(true); }