return missing "/search" and "/site.webmanifest" router

This commit is contained in:
Viacheslav Evseev
2024-02-22 02:40:54 +03:00
parent 0b80e0ada1
commit 3695797f74
4 changed files with 15 additions and 5 deletions

View File

@@ -1,6 +1,7 @@
package api
import (
config "server/settings"
"server/web/auth"
"github.com/gin-gonic/gin"
@@ -39,7 +40,11 @@ func SetupRoute(route gin.IRouter) {
authorized.GET("/download/:size", download)
authorized.GET("/search/*query", rutorSearch)
if config.SearchWA {
route.GET("/search/*query", rutorSearch)
} else {
authorized.GET("/search/*query", rutorSearch)
}
authorized.GET("/ffp/:hash/:id", ffp)
}