Skip to content

Commit 12ad746

Browse files
author
lewzylu
committed
update upload response
1 parent de3e334 commit 12ad746

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/Qcloud/Cos/Client.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,7 @@ public function Upload($bucket, $key, $body, $options = array()) {
121121
) + $options['params']);
122122

123123
$rt['Location'] = $rt['ObjectURL'];
124+
$rt['Location'] = ltrim($rt['Location'], $this->schema. "://");
124125
unset($rt['ObjectURL']);
125126
}
126127
else {
@@ -131,6 +132,8 @@ public function Upload($bucket, $key, $body, $options = array()) {
131132
) + $options['params']);
132133

133134
$rt = $multipartUpload->performUploading();
135+
unset($rt['Bucket']);
136+
unset($rt['Key']);
134137
}
135138
return $rt;
136139
}

0 commit comments

Comments
 (0)