summaryrefslogtreecommitdiffstats
path: root/apps/dav
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2016-12-23 13:44:40 +0100
committerRoeland Jago Douma <roeland@famdouma.nl>2017-03-29 00:04:29 +0200
commit73007255ceac2364f8563c84d6b46e113ff44d82 (patch)
tree06b38e4822059f2953399f6f957ca7c0842fde19 /apps/dav
parent23aab05bdaaaff8310cad64ff028bc7a53656f5a (diff)
downloadnextcloud-server-73007255ceac2364f8563c84d6b46e113ff44d82.tar.gz
nextcloud-server-73007255ceac2364f8563c84d6b46e113ff44d82.zip
Return last modification time to allow proper listing in cadaver
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'apps/dav')
-rw-r--r--apps/dav/lib/Avatars/AvatarNode.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/apps/dav/lib/Avatars/AvatarNode.php b/apps/dav/lib/Avatars/AvatarNode.php
index 0f2bfe1da43..7d606d55cba 100644
--- a/apps/dav/lib/Avatars/AvatarNode.php
+++ b/apps/dav/lib/Avatars/AvatarNode.php
@@ -83,11 +83,16 @@ class AvatarNode extends File {
return 'image/jpeg';
}
-// function getSize() {
-// return $this->avatar->getFile($this->size)->getSize();
-// }
-
function getETag() {
return $this->avatar->getFile($this->size)->getEtag();
}
+
+ function getLastModified() {
+ $timestamp = $this->avatar->getFile($this->size)->getMTime();
+ if (!empty($timestamp)) {
+ return (int)$timestamp;
+ }
+ return $timestamp;
+
+ }
}