Skip to content

Commit

Permalink
docs: fix demo code error of cloud storage
Browse files Browse the repository at this point in the history
  • Loading branch information
maslow committed Jan 5, 2024
1 parent b898eeb commit f1e7297
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/zh/cloud-storage/download-url.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ import cloud from '@lafjs/cloud'
export default async function (ctx: FunctionContext) {
const bucket = cloud.storage.bucket('data')

// 第二个参数为上传地址有效期,单位为秒
const url = bucket.getUploadUrl('index.html', 3600 * 24 * 7)
// 第二个参数为下载地址有效期,单位为秒
const url = bucket.getDownloadUrl('index.html', 3600 * 24 * 7)
return url
}
```

0 comments on commit f1e7297

Please sign in to comment.