public async Task <FunqResult <Minion> > UpdateMinionAsync(Minion minion) { var dbMinion = await _minionReadSvc.GetMinionAsync(minion.Id).ConfigureAwait(false); if (dbMinion == null) { return(FunqFactory.Fail("Unable to find existing minion to update", (Minion)null)); } dbMinion.MovieMoments = minion.MovieMoments; dbMinion.Name = minion.Name; dbMinion.Nickname = minion.Nickname; dbMinion.Traits = minion.Traits; await _appCache.AddOrUpdateAsync(dbMinion.Id.ToString(), dbMinion, null, typeof(Minion).Name).ConfigureAwait(false); return(FunqFactory.KeepGroovin(dbMinion, "Successfully updated minion")); }
// GET: Minions/Details/5 public async Task <ActionResult> Details(Guid id) { var minion = await _minionsReadSvc.GetMinionAsync(id); return(View("MinionDetails", minion)); }