mirror of
https://github.com/astaxie/beego.git
synced 2025-06-23 06:50:18 +00:00
add mis function NSHandler
This commit is contained in:
@ -388,3 +388,10 @@ func NSNamespace(prefix string, params ...LinkNamespace) LinkNamespace {
|
||||
ns.Namespace(n)
|
||||
}
|
||||
}
|
||||
|
||||
// NSHandler add handler
|
||||
func NSHandler(rootpath string, h http.Handler) LinkNamespace {
|
||||
return func(ns *Namespace) {
|
||||
ns.Handler(rootpath, h)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user