mirror of
https://github.com/Ernous/TorrServerJellyfin.git
synced 2025-12-19 21:46:11 +05:00
error on disable rutor
This commit is contained in:
@@ -1,15 +1,21 @@
|
|||||||
package api
|
package api
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"net/http"
|
||||||
"net/url"
|
"net/url"
|
||||||
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
|
|
||||||
"server/rutor"
|
"server/rutor"
|
||||||
"server/rutor/models"
|
"server/rutor/models"
|
||||||
|
sets "server/settings"
|
||||||
)
|
)
|
||||||
|
|
||||||
func rutorSearch(c *gin.Context) {
|
func rutorSearch(c *gin.Context) {
|
||||||
|
if !sets.BTsets.EnableRutorSearch {
|
||||||
|
c.JSON(http.StatusBadRequest, []string{})
|
||||||
|
return
|
||||||
|
}
|
||||||
query := c.Query("query")
|
query := c.Query("query")
|
||||||
query, _ = url.QueryUnescape(query)
|
query, _ = url.QueryUnescape(query)
|
||||||
list := rutor.Search(query)
|
list := rutor.Search(query)
|
||||||
|
|||||||
Reference in New Issue
Block a user