Prefix $path for filename for internal file cache

Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
pull/14211/head
Daniel Kesselberg 7 years ago
parent e65f7f05de
commit 659ed3ecda
No known key found for this signature in database
GPG Key ID: 36E3664E099D0614
  1. 4
      apps/files_external/lib/Lib/Storage/AmazonS3.php

@ -309,7 +309,7 @@ class AmazonS3 extends \OC\Files\Storage\Common {
$files[] = $file;
// store this information for later usage
$this->filesCache[$file] = [
$this->filesCache[$path . $file] = [
'ContentLength' => $object['Size'],
'LastModified' => (string)$object['LastModified'],
];
@ -408,7 +408,7 @@ class AmazonS3 extends \OC\Files\Storage\Common {
}
try {
if ($this->headObject($path)) {
if (isset($this->filesCache[$path]) && $this->headObject($path)) {
return 'file';
}
if ($this->headObject($path . '/')) {

Loading…
Cancel
Save