1
0
mirror of https://github.com/nitezs/sub2clash.git synced 2024-12-25 00:44:42 -05:00
sub2clash/api/route.go
2023-09-13 13:47:22 +08:00

22 lines
329 B
Go

package api
import (
"github.com/gin-gonic/gin"
"sub2clash/api/controller"
"sub2clash/middleware"
)
func SetRoute(r *gin.Engine) {
r.Use(middleware.ZapLogger())
r.GET(
"/clash", func(c *gin.Context) {
controller.SubmodHandler(c)
},
)
r.GET(
"/meta", func(c *gin.Context) {
controller.SubHandler(c)
},
)
}