code: func adaptCheckToHandler(c func(r *http.Request) error) http.HandlerFunc {
  	return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
  		err := c(r)
  		if err != nil {
  			http.Error(w, fmt.Sprintf("internal server error: %v", err), http.StatusInternalServerError)
  		} else {
  			fmt.Fprint(w, "ok")
  		}
  	})
  }
docs: // adaptCheckToHandler returns an http.HandlerFunc that serves the provided checks.