public IHttpActionResult GetFilesByClassId(int classId) { var files = fileRepo.GetFilesByClassId(classId).ToList(); if (!files.Any()) { return(Content(HttpStatusCode.NotFound, "List is empty")); } return(Ok(files)); }