private async Task <ApplicationUser> GetUser(AbstractRosterStoreDbContext context) { var um = new UserManager <ApplicationUser> ( new UserStore <ApplicationUser> (context)); return(await um.FindByIdAsync(user)); }
private async Task <string> SaveNextVersion(AbstractRosterStoreDbContext context) { var user = await GetUser(context); user.RosterVersion = NextVersion(user.RosterVersion); await context.MySaveChanges(); return(VersionString(user.RosterVersion)); }
private async Task <int> NextVersion(AbstractRosterStoreDbContext context) { return(NextVersion(await CurrentVersion(context))); }
private async Task <int> CurrentVersion(AbstractRosterStoreDbContext context) { return((await GetUser(context)).RosterVersion); }