mirror of
https://git.code.sf.net/p/seeddms/code
synced 2024-11-26 15:32:13 +00:00
set propper last modification time
This commit is contained in:
parent
1cb1ffb436
commit
4dade8e5cd
|
@ -276,12 +276,11 @@ class HTTP_WebDAV_Server_SeedDMS extends HTTP_WebDAV_Server
|
|||
$info = array();
|
||||
$info["props"] = array();
|
||||
|
||||
// modification time
|
||||
$info["props"][] = $this->mkprop("getlastmodified", time());
|
||||
|
||||
// type and size (caller already made sure that path exists)
|
||||
if (get_class($obj) == 'SeedDMS_Core_Folder') {
|
||||
// modification time
|
||||
/* folders do not have a modification time */
|
||||
$info["props"][] = $this->mkprop("getlastmodified", time());
|
||||
$info["props"][] = $this->mkprop("creationdate", time());
|
||||
|
||||
// directory (WebDAV collection)
|
||||
|
@ -301,6 +300,8 @@ class HTTP_WebDAV_Server_SeedDMS extends HTTP_WebDAV_Server
|
|||
$info["props"][] = $this->mkprop("resourcetype", "collection");
|
||||
$info["props"][] = $this->mkprop("getcontenttype", "httpd/unix-directory");
|
||||
} else {
|
||||
// modification time
|
||||
$info["props"][] = $this->mkprop("getlastmodified",$obj->getLatestContent()->getDate());
|
||||
$info["props"][] = $this->mkprop("creationdate", $obj->getDate());
|
||||
|
||||
// plain file (WebDAV resource)
|
||||
|
|
Loading…
Reference in New Issue
Block a user