diff --git a/application/Espo/Core/Utils/File/Manager.php b/application/Espo/Core/Utils/File/Manager.php index eb0c39a481..941a115e10 100644 --- a/application/Espo/Core/Utils/File/Manager.php +++ b/application/Espo/Core/Utils/File/Manager.php @@ -466,6 +466,9 @@ class Manager if (file_exists($sourceFile) && is_file($sourceFile)) { $res &= copy($sourceFile, $destFile); + if (function_exists('opcache_invalidate')) { + opcache_invalidate($destFile); + } } } @@ -558,6 +561,9 @@ class Manager } if (file_exists($filePath) && is_file($filePath)) { + if (function_exists('opcache_invalidate')) { + opcache_invalidate($filePath, true); + } $result &= unlink($filePath); } }