Mr.L
feat: add full alist source code for Docker build
7107f0b
raw
history blame contribute delete
438 Bytes
package common
import (
stdpath "path"
"github.com/alist-org/alist/v3/internal/conf"
"github.com/alist-org/alist/v3/internal/model"
"github.com/alist-org/alist/v3/internal/setting"
"github.com/alist-org/alist/v3/internal/sign"
)
func Sign(obj model.Obj, parent string, encrypt bool) string {
if obj.IsDir() || (!encrypt && !setting.GetBool(conf.SignAll)) {
return ""
}
return sign.Sign(stdpath.Join(parent, obj.GetName()))
}