Example #1
0
        public async Task <IActionResult> FollowUser(string userId, CancellationToken cancellationToken)
        {
            var identifier = User.GetUserId();

            var command = new AddFollowCommand
            {
                Follow = new FollowRequest
                {
                    FolloweeId = Guid.Parse(userId),
                    FollowerId = identifier
                }
            };

            await _mediator.Send(command, cancellationToken);

            return(NoContent());
        }
Example #2
0
 public ActionResult FollowThisStore(AddFollowCommand command)
 {
     return(TryPush(command));
 }