fix(drivers/github): failed to get objs (#1915)

fix(drivers/github): failed get objs
This commit is contained in:
KirCute
2026-01-16 12:07:27 +08:00
committed by GitHub
parent 5c82f55200
commit 378e37b082

View File

@@ -4,6 +4,7 @@ import (
"time"
"github.com/OpenListTeam/OpenList/v4/internal/model"
"github.com/OpenListTeam/OpenList/v4/pkg/utils"
)
type Links struct {
@@ -36,6 +37,7 @@ func (o *Object) toModelObj() *model.Object {
Size: o.Size,
Modified: time.Unix(0, 0),
IsFolder: o.Type == "dir",
Path: utils.FixAndCleanPath(o.Path),
}
}
@@ -69,6 +71,7 @@ func (o *TreeObjResp) toModelObj() *model.Object {
Size: o.Size,
Modified: time.Unix(0, 0),
IsFolder: o.Type == "tree",
Path: utils.FixAndCleanPath(o.Path),
}
}