Example #1
0
        public IActionResult UpdateHeroTitleInline(string id, [FromForm] string title)
        {
            var model = _heroService.GetModel(id);

            if (model != null)
            {
                model.Title = title;
                _heroService.UpdateModel(model);

                return(Ok(model));
            }

            return(BadRequest($"Could not locate hero model for Id: {id}"));
        }