diff options
author | Björn Schießle <schiessle@owncloud.com> | 2013-03-07 15:51:44 +0100 |
---|---|---|
committer | Björn Schießle <schiessle@owncloud.com> | 2013-03-07 15:51:44 +0100 |
commit | 48bb53030c657e1133da47765c7c778a069af665 (patch) | |
tree | 5e38ce80da83978e8e7c4cc9f4a4bb916f2fae39 /apps/files_versions/lib | |
parent | 70f0e0a8da73f8eac3ec63e558377068a0e0a3b0 (diff) | |
download | nextcloud-server-48bb53030c657e1133da47765c7c778a069af665.tar.gz nextcloud-server-48bb53030c657e1133da47765c7c778a069af665.zip |
distinguish between touch and write
Diffstat (limited to 'apps/files_versions/lib')
-rw-r--r-- | apps/files_versions/lib/hooks.php | 6 | ||||
-rw-r--r-- | apps/files_versions/lib/versions.php | 1 |
2 files changed, 7 insertions, 0 deletions
diff --git a/apps/files_versions/lib/hooks.php b/apps/files_versions/lib/hooks.php index 7891b20e92f..6e81286052f 100644 --- a/apps/files_versions/lib/hooks.php +++ b/apps/files_versions/lib/hooks.php @@ -21,6 +21,12 @@ class Hooks { if(\OCP\Config::getSystemValue('files_versions', Storage::DEFAULTENABLED)=='true') { $path = $params[\OC\Files\Filesystem::signal_param_path]; + $pos = strrpos($path, '.part'); + if ($pos) { + error_log("old path: $path"); + $path = substr($path, 0, $pos); + error_log("new path: $path"); + } if($path<>'') { Storage::store($path); } diff --git a/apps/files_versions/lib/versions.php b/apps/files_versions/lib/versions.php index c37133cf32c..274f38095db 100644 --- a/apps/files_versions/lib/versions.php +++ b/apps/files_versions/lib/versions.php @@ -107,6 +107,7 @@ class Storage { // store a new version of a file $users_view->copy('files'.$filename, 'files_versions'.$filename.'.v'.$users_view->filemtime('files'.$filename)); + error_log("version created!"); $versionsSize = self::getVersionsSize($uid); if ( $versionsSize === false || $versionsSize < 0 ) { $versionsSize = self::calculateSize($uid); |