🎨 Improve upload assets tip

This commit is contained in:
Daniel 2024-01-01 16:48:52 +08:00
parent 876e95ef27
commit b9f1da33f0
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
7 changed files with 15 additions and 9 deletions

View file

@ -509,13 +509,17 @@ func GetAssetAbsPath(relativePath string) (ret string, err error) {
return "", errors.New(fmt.Sprintf(Conf.Language(12), relativePath))
}
func UploadAssets2Cloud(rootID string) (err error) {
func UploadAssets2Cloud(rootID string) (count int, err error) {
if !IsSubscriber() {
return
}
sqlAssets := sql.QueryRootBlockAssets(rootID)
err = uploadAssets2Cloud(sqlAssets, bizTypeUploadAssets)
if nil != err {
return
}
count = len(sqlAssets)
return
}