mirror of
https://github.com/Ernous/TorrServerJellyfin.git
synced 2025-12-19 21:46:11 +05:00
fix build
gofmt -l -w .
This commit is contained in:
@@ -9,7 +9,7 @@ import (
|
|||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
)
|
)
|
||||||
|
|
||||||
//Action: get
|
// Action: get
|
||||||
type cacheReqJS struct {
|
type cacheReqJS struct {
|
||||||
requestI
|
requestI
|
||||||
Hash string `json:"hash,omitempty"`
|
Hash string `json:"hash,omitempty"`
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ import (
|
|||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
)
|
)
|
||||||
|
|
||||||
//Action: add, get, set, rem, list, drop
|
// Action: add, get, set, rem, list, drop
|
||||||
type torrReqJS struct {
|
type torrReqJS struct {
|
||||||
requestI
|
requestI
|
||||||
Link string `json:"link,omitempty"`
|
Link string `json:"link,omitempty"`
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ package msx
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
_ "embed"
|
_ "embed"
|
||||||
|
|
||||||
"server/version"
|
"server/version"
|
||||||
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
@@ -23,16 +23,11 @@ var (
|
|||||||
rus []byte
|
rus []byte
|
||||||
)
|
)
|
||||||
|
|
||||||
func ass(b []byte, t string) func(*gin.Context) {
|
|
||||||
return func(c *gin.Context) {
|
|
||||||
c.Header("Content-Encoding", "gzip")
|
|
||||||
c.Data(200, t+"; charset=UTF-8", b)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
func ass(c *gin.Context, b []byte, t string) {
|
func ass(c *gin.Context, b []byte, t string) {
|
||||||
c.Header("Content-Encoding", "gzip")
|
c.Header("Content-Encoding", "gzip")
|
||||||
c.Data(200, t+"; charset=UTF-8", b)
|
c.Data(200, t+"; charset=UTF-8", b)
|
||||||
}
|
}
|
||||||
|
|
||||||
func SetupRoute(r *gin.RouterGroup) {
|
func SetupRoute(r *gin.RouterGroup) {
|
||||||
r.GET("/msx/:pth", func(c *gin.Context) {
|
r.GET("/msx/:pth", func(c *gin.Context) {
|
||||||
s := []string{"tvx", "tizen"}
|
s := []string{"tvx", "tizen"}
|
||||||
|
|||||||
Reference in New Issue
Block a user