Return last modification time to allow proper listing in cadaver

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
This commit is contained in:
Thomas Müller 2016-12-23 13:44:40 +01:00 committed by Roeland Jago Douma
parent 23aab05bda
commit 73007255ce
No known key found for this signature in database
GPG Key ID: F941078878347C0C
1 changed files with 9 additions and 4 deletions

View File

@ -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;
}
}