Example #1
0
        public async Task <IActionResult> GetPaymentForUser(int userId)
        {
            if (userId != int.Parse(User.FindFirst(ClaimTypes.NameIdentifier).Value))
            {
                return(Unauthorized());
            }
            var payment = await _repo.GetPaymentForUser(userId);

            return(Ok(payment));
        }