Skip to content

Commit 1fa524c

Browse files
authored
Merge pull request #40 from OVINC-CN/feat_put_obj
feat(cos): change upload method
2 parents 1a91861 + 2250f3b commit 1fa524c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/views/EditDoc.vue

+2-2
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ const uploadHeaderImg = (option) => {
152152
(res) => {
153153
const credentials = res.data;
154154
const cos = loadCos(credentials);
155-
cos.uploadFile({
155+
cos.putObject({
156156
Bucket: credentials.cos_bucket,
157157
Region: credentials.cos_region,
158158
Key: credentials.key,
@@ -193,7 +193,7 @@ const handleFileUpload = (editor, files) => {
193193
(res) => {
194194
const credentials = res.data;
195195
const cos = loadCos(credentials);
196-
cos.uploadFile({
196+
cos.putObject({
197197
Bucket: credentials.cos_bucket,
198198
Region: credentials.cos_region,
199199
Key: credentials.key,

0 commit comments

Comments
 (0)