Example #1
0
 public async Task <ActionResult <HostedFile> > EditHostedFile(int id, [FromBody] HostedFile file)
 {
     try
     {
         return(await _context.EditHostedFile(id, file));
     }
     catch (ControllerNotFoundException e)
     {
         return(NotFound(e.Message));
     }
     catch (ControllerBadRequestException e)
     {
         return(BadRequest(e.Message));
     }
 }