From 7c77e7431478ac67be34eec6dd10325233a2f64e Mon Sep 17 00:00:00 2001 From: dartcafe Date: Wed, 19 May 2021 13:55:29 +0200 Subject: [PATCH] fix #25813 Signed-off-by: dartcafe --- lib/public/Log/RotationTrait.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/public/Log/RotationTrait.php b/lib/public/Log/RotationTrait.php index d7de50410d6..6c6ea955f03 100644 --- a/lib/public/Log/RotationTrait.php +++ b/lib/public/Log/RotationTrait.php @@ -58,7 +58,7 @@ trait RotationTrait { * @since 14.0.0 */ protected function shouldRotateBySize():bool { - if ((int)$this->maxSize > 0) { + if ((int)$this->maxSize > 0 && file_exist($this->filePath)) { $filesize = @filesize($this->filePath); if ($filesize >= (int)$this->maxSize) { return true;