public JsonResult Post(string profileUserFirstName, [FromBody] OtherCourseViewModel vm)
        {
            try
            {
                if (ModelState.IsValid)
                {
                    //Map to the Entity
                    var newOtherCourse = Mapper.Map <OtherCourse>(vm);

                    //Save to Database
                    _repository.AddOtherCourse(profileUserFirstName, User.Identity.Name, newOtherCourse);

                    if (_repository.SaveAll())
                    {
                        Response.StatusCode = (int)HttpStatusCode.Created;
                        return(Json(Mapper.Map <OtherCourseViewModel>(newOtherCourse)));
                    }
                }
            }
            catch (Exception ex)
            {
                _logger.LogError($"Failed to save new course", ex);
                Response.StatusCode = (int)HttpStatusCode.BadRequest;
                return(Json("Error occured save new course"));
            }
            Response.StatusCode = (int)HttpStatusCode.BadRequest;
            return(Json("Validation failed on new course"));
        }
        public JsonResult Post([FromBody] ProfileUserViewModel vm)
        {
            try
            {
                if (ModelState.IsValid)
                {
                    //Mapper
                    var newProfileUser = Mapper.Map <ProfileUser>(vm);

                    newProfileUser.UserName = User.Identity.Name;

                    //Logger
                    _logger.LogInformation("Attemting to save new profile user");

                    //Save to Database
                    _repository.AddTrip(newProfileUser);

                    if (_repository.SaveAll())
                    {
                        //return
                        Response.StatusCode = (int)HttpStatusCode.Created;
                        return(Json(Mapper.Map <ProfileUserViewModel>(newProfileUser)));
                    }
                }
            }
            catch (Exception ex)
            {
                //_logger.LogError("Failde to save new trip", ex);
                Response.StatusCode = (int)HttpStatusCode.BadRequest;
                return(Json(new { Message = ex.Message }));
            }


            Response.StatusCode = (int)HttpStatusCode.BadRequest;
            return(Json(new { Message = "Failed", ModelState = ModelState }));
        }