public async Task <Athlete> SaveAthleteAync(Athlete athlete, string userId) { athlete.ApplicationUserId = userId; var dbAthlete = athlete.Map <Data.Entities.Athelete>(); await _repo.Atheletes.DeleteAndSaveAsync(_repo.Atheletes.Where(m => m.ApplicationUserId == userId).ToList()); await _repo.Atheletes.AddOrUpdateAndSaveAsync(dbAthlete); return(dbAthlete.Map <Athlete>()); }