diff options
author | Louis Chemineau <louis@chmn.me> | 2022-12-08 11:26:58 +0100 |
---|---|---|
committer | Louis (Rebase PR Action) <artonge@users.noreply.github.com> | 2023-01-26 10:12:23 +0000 |
commit | c88328e68e50341fa3e22181ffb9b25ae7071ed7 (patch) | |
tree | f8703ffaf691dfb264d261dc491ddde8e1e87543 /apps/files_versions/lib/Sabre/VersionFile.php | |
parent | d8b479752d327f8901a84454c17fd3c6f701a98d (diff) | |
download | nextcloud-server-c88328e68e50341fa3e22181ffb9b25ae7071ed7.tar.gz nextcloud-server-c88328e68e50341fa3e22181ffb9b25ae7071ed7.zip |
Handle empty files in version creation logic
Signed-off-by: Louis Chemineau <louis@chmn.me>
Diffstat (limited to 'apps/files_versions/lib/Sabre/VersionFile.php')
-rw-r--r-- | apps/files_versions/lib/Sabre/VersionFile.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files_versions/lib/Sabre/VersionFile.php b/apps/files_versions/lib/Sabre/VersionFile.php index 12590fe9efd..20ae25a7623 100644 --- a/apps/files_versions/lib/Sabre/VersionFile.php +++ b/apps/files_versions/lib/Sabre/VersionFile.php @@ -89,7 +89,7 @@ class VersionFile implements IFile { } public function getLabel(): ?string { - if ($this->version instanceof INameableVersion) { + if ($this->version instanceof INameableVersion && $this->version->getSourceFile()->getSize() > 0) { return $this->version->getLabel(); } else { return null; |