private void OnDestroy()
 {
     if (httpServer != null)
     {
         httpServer.RemoveEndpoint(httpMethod, urlPattern);
     }
 }
 public static void RemoveEndpoint(this HttpServer httpServer, EndpointHandler endpointHandler)
 {
     httpServer.RemoveEndpoint(endpointHandler.HttpMethod, endpointHandler.UrlPattern);
 }