public IActionResult GetUserPayTypes(int userId) { var findUser = _userRepository.GetUserById(userId); if (findUser == null) { return(NotFound("This user could not be found.")); } var PaymentOptions = _repository.GetPaymentTypesByUser(userId); var noSavedPayTypes = !PaymentOptions.Any(); if (noSavedPayTypes) { return(NotFound("You do not have any saved payment types, please create a new one.")); } return(Ok(PaymentOptions)); }