✨ ali path and link
This commit is contained in:
@ -1,9 +1,19 @@
|
||||
package server
|
||||
|
||||
import "github.com/gofiber/fiber/v2"
|
||||
import (
|
||||
"github.com/Xhofe/alist/utils"
|
||||
"github.com/gofiber/fiber/v2"
|
||||
log "github.com/sirupsen/logrus"
|
||||
"net/url"
|
||||
)
|
||||
|
||||
func Down(ctx *fiber.Ctx) error {
|
||||
rawPath := ctx.Params("*")
|
||||
rawPath, err:= url.QueryUnescape(ctx.Params("*"))
|
||||
if err != nil {
|
||||
return ErrorResp(ctx,err,500)
|
||||
}
|
||||
rawPath = utils.ParsePath(rawPath)
|
||||
log.Debugf("down: %s",rawPath)
|
||||
account, path, driver, err := ParsePath(rawPath)
|
||||
if err != nil {
|
||||
return ErrorResp(ctx, err, 500)
|
||||
|
Reference in New Issue
Block a user