public async Task <Video> CreateVideo(Video video) { _videosContext.Video.Add(video); var rows = await _videosContext.SaveChangesAsync(); if (rows > 0) { return(video); } throw new Exception("There was an error creating video"); }