mirror of
https://github.com/AlistGo/alist.git
synced 2025-04-26 23:34:03 +08:00
14 lines
251 B
Go
14 lines
251 B
Go
package common
|
|
|
|
import (
|
|
"github.com/alist-org/alist/v3/internal/model"
|
|
"github.com/alist-org/alist/v3/internal/sign"
|
|
)
|
|
|
|
func Sign(obj model.Obj, encrypt bool) string {
|
|
if obj.IsDir() || !encrypt {
|
|
return ""
|
|
}
|
|
return sign.Sign(obj.GetName())
|
|
}
|