From 67d5380b91a1c970a62d04dc82e1ccae10d0d862 Mon Sep 17 00:00:00 2001 From: Daniel Kesselberg Date: Sun, 30 Sep 2018 21:05:53 +0200 Subject: Reuse information from ListObjects for stat / filetype Signed-off-by: Daniel Kesselberg --- apps/files_external/lib/Lib/Storage/AmazonS3.php | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'apps/files_external/lib') diff --git a/apps/files_external/lib/Lib/Storage/AmazonS3.php b/apps/files_external/lib/Lib/Storage/AmazonS3.php index 097b196b2d4..94ada029809 100644 --- a/apps/files_external/lib/Lib/Storage/AmazonS3.php +++ b/apps/files_external/lib/Lib/Storage/AmazonS3.php @@ -301,6 +301,11 @@ class AmazonS3 extends \OC\Files\Storage\Common { isset($object['Key']) ? $object['Key'] : $object['Prefix'] ); $files[] = $file; + + $this->objectCache->set($file, [ + 'ContentLength' => $object['Size'], + 'LastModified' => (string)$object['LastModified'], + ]); } } } -- cgit v1.2.3