public async Task <IActionResult> PutSongsTable(int id, SongsTable songsTable) { if (id != songsTable.Id) { return(BadRequest()); } _context.Entry(songsTable).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!SongsTableExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }
public async Task <IActionResult> PutAddPlay(int id, AddPlay addPlay) { if (id != addPlay.PlayId) { return(BadRequest()); } _context.Entry(addPlay).State = EntityState.Modified; try { await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!AddPlayExists(id)) { return(NotFound()); } else { throw; } } return(NoContent()); }