You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: middleware.go
    path of file: ./repos/Tigo/web
    
    the code of the file until where you have to start completion: package web

import (
	"errors"
	"github.com/gorilla/mux"
	"github.com/karldoenitz/Tigo/logger"
	"net/http"
	"time"
)

// middleware http中间件
type middleware func(next http.HandlerFunc) http.HandlerFunc

// Middleware Tigo的中间件类型，函数返回值true表示h
    
func convertHandleMV(v Middleware) mux.MiddlewareFunc {
	return func(next http.Handler) http.Handler {
		return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
			// 此处需要判断请求是否继续交给下一个中间件处理
			if isGoOn := v(&w, r); isGoOn {
				next.ServeHTTP(w, r)
			}
		})
	}
}