rename a file if it gets restored so that it no longer exists as a version. Otherwise it can happen that the expire() function removes all other versions so that we end up with only one version which is exactly the same as the original file
This commit is contained in:
parent
0e30e68b22
commit
bda8187f3b
|
@ -200,7 +200,7 @@ class Storage {
|
|||
}
|
||||
|
||||
// rollback
|
||||
if( @$users_view->copy('files_versions'.$filename.'.v'.$revision, 'files'.$filename) ) {
|
||||
if( @$users_view->rename('files_versions'.$filename.'.v'.$revision, 'files'.$filename) ) {
|
||||
$files_view->touch($file, $revision);
|
||||
Storage::expire($file);
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue