public ActionResult <IEnumerable <Product> > Get()
 {
     try
     {
         return(Ok(repository.GetAllProducts()));
     }
     catch (Exception e)
     {
         logger.LogError($"Failed to get products: {e}");
         return(BadRequest("Bad Request"));
     }
 }