File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
lib/private/Files/ObjectStore Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -191,14 +191,20 @@ public function objectExists($urn) {
191191 }
192192
193193 public function copyObject ($ from , $ to , array $ options = []) {
194+ $ sourceMetadata = $ this ->getConnection ()->headObject ([
195+ 'Bucket ' => $ this ->getBucket (),
196+ 'Key ' => $ from ,
197+ ] + $ this ->getSSECParameters ());
198+
194199 $ copy = new MultipartCopy ($ this ->getConnection (), [
195200 "source_bucket " => $ this ->getBucket (),
196201 "source_key " => $ from
197202 ], array_merge ([
198203 "bucket " => $ this ->getBucket (),
199204 "key " => $ to ,
200205 "acl " => "private " ,
201- "params " => $ this ->getSSECParameters () + $ this ->getSSECParameters (true )
206+ "params " => $ this ->getSSECParameters () + $ this ->getSSECParameters (true ),
207+ "source_metadata " => $ sourceMetadata
202208 ], $ options ));
203209 $ copy ->copy ();
204210 }
You can’t perform that action at this time.
0 commit comments