Skip to content

Commit

Permalink
feat: 七牛云备份账号支持设置超时时间
Browse files Browse the repository at this point in the history
  • Loading branch information
john1298308460 committed Jul 10, 2024
1 parent 189f209 commit 354c453
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion backend/utils/cloud_storage/client/kodo.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ func NewKodoClient(vars map[string]interface{}) (*kodoClient, error) {
bucket := loadParamFromVars("bucket", vars)
domain := loadParamFromVars("domain", vars)
timeout := loadParamFromVars("timeout", vars)

if timeout == "" {
timeout = "1"
}
conn := auth.New(accessKey, secretKey)
cfg := storage.Config{
UseHTTPS: false,
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/views/setting/backup-account/kodo/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ const acceptParams = (params: DialogProps): void => {
domainProto.value = httpItem.proto;
}
title.value = i18n.global.t('commons.button.' + kodoData.value.title);
if (kodoData.value.rowData!.varsJson['timeout'] == undefined) {
if (kodoData.value.rowData!.varsJson['timeout'] === undefined) {
kodoData.value.rowData!.varsJson['timeout'] = 1;
}
drawerVisible.value = true;
Expand Down

0 comments on commit 354c453

Please sign in to comment.