public async Task <IActionResult> PutProfil(int id, Profil profil) { if (id != profil.Id) { return(BadRequest()); } _context.Entry(profil).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!ProfilExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }