From b09620651cbb72e5a623d47ed409e949b114c7cf Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Thu, 20 Aug 2020 14:08:18 +0200 Subject: [PATCH 1/4] Don't use deprecated getIniWrapper() anymore Signed-off-by: Joas Schilling --- apps/files_sharing/templates/public.php | 4 ++-- .../lib/Controller/CheckSetupController.php | 18 ++++++++++-------- core/Command/Maintenance/Install.php | 12 +++++++----- lib/base.php | 2 +- lib/private/LargeFileHelper.php | 4 +++- lib/private/Memcache/APCu.php | 5 +++-- lib/private/Server.php | 4 ++-- lib/private/Setup.php | 2 +- lib/private/TempManager.php | 16 ++++++++-------- lib/private/TemplateLayout.php | 5 +++-- lib/private/legacy/OC_Files.php | 3 ++- lib/private/legacy/OC_Helper.php | 7 ++++--- lib/private/legacy/OC_Util.php | 5 +++-- tests/lib/LargeFileHelperGetFileSizeTest.php | 4 +++- 14 files changed, 52 insertions(+), 39 deletions(-) diff --git a/apps/files_sharing/templates/public.php b/apps/files_sharing/templates/public.php index 82544385de..ffc449f9e6 100644 --- a/apps/files_sharing/templates/public.php +++ b/apps/files_sharing/templates/public.php @@ -23,8 +23,8 @@ getIniWrapper()->getBytes('upload_max_filesize'); -$post_max_size = OC::$server->getIniWrapper()->getBytes('post_max_size'); +$upload_max_filesize = OC::$server->get(\bantu\IniGetWrapper\IniGetWrapper::class)->getBytes('upload_max_filesize'); +$post_max_size = OC::$server->get(\bantu\IniGetWrapper\IniGetWrapper::class)->getBytes('post_max_size'); $maxUploadFilesize = min($upload_max_filesize, $post_max_size); ?> diff --git a/apps/settings/lib/Controller/CheckSetupController.php b/apps/settings/lib/Controller/CheckSetupController.php index 476b58e564..6d237e04c1 100644 --- a/apps/settings/lib/Controller/CheckSetupController.php +++ b/apps/settings/lib/Controller/CheckSetupController.php @@ -98,6 +98,8 @@ class CheckSetupController extends Controller { private $memoryInfo; /** @var ISecureRandom */ private $secureRandom; + /** @var IniGetWrapper */ + private $iniGetWrapper; public function __construct($AppName, IRequest $request, @@ -112,7 +114,8 @@ class CheckSetupController extends Controller { ILockingProvider $lockingProvider, IDateTimeFormatter $dateTimeFormatter, MemoryInfo $memoryInfo, - ISecureRandom $secureRandom) { + ISecureRandom $secureRandom, + IniGetWrapper $iniGetWrapper) { parent::__construct($AppName, $request); $this->config = $config; $this->clientService = $clientService; @@ -126,6 +129,7 @@ class CheckSetupController extends Controller { $this->dateTimeFormatter = $dateTimeFormatter; $this->memoryInfo = $memoryInfo; $this->secureRandom = $secureRandom; + $this->iniGetWrapper = $iniGetWrapper; } /** @@ -407,25 +411,23 @@ Raw output * @return bool */ protected function isOpcacheProperlySetup() { - $iniWrapper = new IniGetWrapper(); - - if (!$iniWrapper->getBool('opcache.enable')) { + if (!$this->iniGetWrapper->getBool('opcache.enable')) { return false; } - if (!$iniWrapper->getBool('opcache.save_comments')) { + if (!$this->iniGetWrapper->getBool('opcache.save_comments')) { return false; } - if ($iniWrapper->getNumeric('opcache.max_accelerated_files') < 10000) { + if ($this->iniGetWrapper->getNumeric('opcache.max_accelerated_files') < 10000) { return false; } - if ($iniWrapper->getNumeric('opcache.memory_consumption') < 128) { + if ($this->iniGetWrapper->getNumeric('opcache.memory_consumption') < 128) { return false; } - if ($iniWrapper->getNumeric('opcache.interned_strings_buffer') < 8) { + if ($this->iniGetWrapper->getNumeric('opcache.interned_strings_buffer') < 8) { return false; } diff --git a/core/Command/Maintenance/Install.php b/core/Command/Maintenance/Install.php index 9cca77bb9c..a8032e24af 100644 --- a/core/Command/Maintenance/Install.php +++ b/core/Command/Maintenance/Install.php @@ -32,6 +32,7 @@ namespace OC\Core\Command\Maintenance; +use bantu\IniGetWrapper\IniGetWrapper; use InvalidArgumentException; use OC\Installer; use OC\Setup; @@ -46,14 +47,15 @@ use Symfony\Component\Console\Question\Question; class Install extends Command { - /** - * @var SystemConfig - */ + /** @var SystemConfig */ private $config; + /** @var IniGetWrapper */ + private $iniGetWrapper; - public function __construct(SystemConfig $config) { + public function __construct(SystemConfig $config, IniGetWrapper $iniGetWrapper) { parent::__construct(); $this->config = $config; + $this->iniGetWrapper = $iniGetWrapper; } protected function configure() { @@ -79,7 +81,7 @@ class Install extends Command { $server = \OC::$server; $setupHelper = new Setup( $this->config, - $server->getIniWrapper(), + $this->iniGetWrapper, $server->getL10N('lib'), $server->query(Defaults::class), $server->getLogger(), diff --git a/lib/base.php b/lib/base.php index 8b8e8e5fe3..6b715f9c24 100644 --- a/lib/base.php +++ b/lib/base.php @@ -936,7 +936,7 @@ class OC { \OC::$server->getSession()->clear(); $setupHelper = new OC\Setup( $systemConfig, - \OC::$server->getIniWrapper(), + \OC::$server->get(\bantu\IniGetWrapper\IniGetWrapper::class), \OC::$server->getL10N('lib'), \OC::$server->query(\OCP\Defaults::class), \OC::$server->getLogger(), diff --git a/lib/private/LargeFileHelper.php b/lib/private/LargeFileHelper.php index 2a6a6714eb..c4e76d22c5 100755 --- a/lib/private/LargeFileHelper.php +++ b/lib/private/LargeFileHelper.php @@ -29,6 +29,8 @@ namespace OC; +use bantu\IniGetWrapper\IniGetWrapper; + /** * Helper class for large files on 32-bit platforms. */ @@ -117,7 +119,7 @@ class LargeFileHelper { * null on failure. */ public function getFileSizeViaCurl($fileName) { - if (\OC::$server->getIniWrapper()->getString('open_basedir') === '') { + if (\OC::$server->get(IniGetWrapper::class)->getString('open_basedir') === '') { $encodedFileName = rawurlencode($fileName); $ch = curl_init("file:///$encodedFileName"); curl_setopt($ch, CURLOPT_NOBODY, true); diff --git a/lib/private/Memcache/APCu.php b/lib/private/Memcache/APCu.php index 87d72ec196..f7ef6eb2d3 100644 --- a/lib/private/Memcache/APCu.php +++ b/lib/private/Memcache/APCu.php @@ -28,6 +28,7 @@ namespace OC\Memcache; +use bantu\IniGetWrapper\IniGetWrapper; use OCP\IMemcache; class APCu extends Cache implements IMemcache { @@ -154,9 +155,9 @@ class APCu extends Cache implements IMemcache { public static function isAvailable() { if (!extension_loaded('apcu')) { return false; - } elseif (!\OC::$server->getIniWrapper()->getBool('apc.enabled')) { + } elseif (!\OC::$server->get(IniGetWrapper::class)->getBool('apc.enabled')) { return false; - } elseif (!\OC::$server->getIniWrapper()->getBool('apc.enable_cli') && \OC::$CLI) { + } elseif (!\OC::$server->get(IniGetWrapper::class)->getBool('apc.enable_cli') && \OC::$CLI) { return false; } elseif ( version_compare(phpversion('apc') ?: '0.0.0', '4.0.6') === -1 && diff --git a/lib/private/Server.php b/lib/private/Server.php index 9b452f21ce..e1dce286a2 100644 --- a/lib/private/Server.php +++ b/lib/private/Server.php @@ -1012,7 +1012,7 @@ class Server extends ServerContainer implements IServerContainer { return $factory->getLDAPProvider(); }); $this->registerService(ILockingProvider::class, function (Server $c) { - $ini = $c->getIniWrapper(); + $ini = $c->get(IniGetWrapper::class); $config = $c->getConfig(); $ttl = $config->getSystemValue('filelocking.ttl', max(3600, $ini->getNumeric('max_execution_time'))); if ($config->getSystemValue('filelocking.enabled', true) or (defined('PHPUNIT_RUN') && PHPUNIT_RUN)) { @@ -1953,7 +1953,7 @@ class Server extends ServerContainer implements IServerContainer { * @deprecated */ public function getIniWrapper() { - return $this->query('IniWrapper'); + return $this->query(IniGetWrapper::class); } /** diff --git a/lib/private/Setup.php b/lib/private/Setup.php index 775c2d0a95..839ef9f7be 100644 --- a/lib/private/Setup.php +++ b/lib/private/Setup.php @@ -503,7 +503,7 @@ class Setup { $setupHelper = new \OC\Setup( $config, - \OC::$server->getIniWrapper(), + \OC::$server->get(IniGetWrapper::class), \OC::$server->getL10N('lib'), \OC::$server->query(Defaults::class), \OC::$server->getLogger(), diff --git a/lib/private/TempManager.php b/lib/private/TempManager.php index 49d4ee94cf..b4db44f6b1 100644 --- a/lib/private/TempManager.php +++ b/lib/private/TempManager.php @@ -31,30 +31,30 @@ namespace OC; +use bantu\IniGetWrapper\IniGetWrapper; use OCP\IConfig; -use OCP\ILogger; use OCP\ITempManager; +use Psr\Log\LoggerInterface; class TempManager implements ITempManager { /** @var string[] Current temporary files and folders, used for cleanup */ protected $current = []; /** @var string i.e. /tmp on linux systems */ protected $tmpBaseDir; - /** @var ILogger */ + /** @var LoggerInterface */ protected $log; /** @var IConfig */ protected $config; + /** @var IniGetWrapper */ + protected $iniGetWrapper; /** Prefix */ public const TMP_PREFIX = 'oc_tmp_'; - /** - * @param \OCP\ILogger $logger - * @param \OCP\IConfig $config - */ - public function __construct(ILogger $logger, IConfig $config) { + public function __construct(LoggerInterface $logger, IConfig $config, IniGetWrapper $iniGetWrapper) { $this->log = $logger; $this->config = $config; + $this->iniGetWrapper = $iniGetWrapper; $this->tmpBaseDir = $this->getTempBaseDir(); } @@ -218,7 +218,7 @@ class TempManager implements ITempManager { if ($temp = $this->config->getSystemValue('tempdirectory', null)) { $directories[] = $temp; } - if ($temp = \OC::$server->getIniWrapper()->get('upload_tmp_dir')) { + if ($temp = $this->iniGetWrapper->get('upload_tmp_dir')) { $directories[] = $temp; } if ($temp = getenv('TMP')) { diff --git a/lib/private/TemplateLayout.php b/lib/private/TemplateLayout.php index af3aeb440d..4a0ec75b51 100644 --- a/lib/private/TemplateLayout.php +++ b/lib/private/TemplateLayout.php @@ -44,6 +44,7 @@ namespace OC; +use bantu\IniGetWrapper\IniGetWrapper; use OC\Search\SearchQuery; use OC\Template\JSCombiner; use OC\Template\JSConfigHelper; @@ -202,7 +203,7 @@ class TemplateLayout extends \OC_Template { \OC::$server->getUserSession()->getUser(), $this->config, \OC::$server->getGroupManager(), - \OC::$server->getIniWrapper(), + \OC::$server->get(IniGetWrapper::class), \OC::$server->getURLGenerator(), \OC::$server->getCapabilitiesManager(), \OC::$server->query(IInitialStateService::class) @@ -259,7 +260,7 @@ class TemplateLayout extends \OC_Template { } } } - + $this->assign('initialStates', $this->initialState->getInitialStates()); } diff --git a/lib/private/legacy/OC_Files.php b/lib/private/legacy/OC_Files.php index ddb824cd6c..f5f91fc995 100644 --- a/lib/private/legacy/OC_Files.php +++ b/lib/private/legacy/OC_Files.php @@ -41,6 +41,7 @@ * */ +use bantu\IniGetWrapper\IniGetWrapper; use OC\Files\View; use OC\Streamer; use OCP\Lock\ILockingProvider; @@ -164,7 +165,7 @@ class OC_Files { OC_Util::obEnd(); $streamer->sendHeaders($name); - $executionTime = (int)OC::$server->getIniWrapper()->getNumeric('max_execution_time'); + $executionTime = (int)OC::$server->get(IniGetWrapper::class)->getNumeric('max_execution_time'); if (strpos(@ini_get('disable_functions'), 'set_time_limit') === false) { @set_time_limit(0); } diff --git a/lib/private/legacy/OC_Helper.php b/lib/private/legacy/OC_Helper.php index 8cd492de11..4e9c5cffe9 100644 --- a/lib/private/legacy/OC_Helper.php +++ b/lib/private/legacy/OC_Helper.php @@ -44,6 +44,7 @@ * */ +use bantu\IniGetWrapper\IniGetWrapper; use Symfony\Component\Process\ExecutableFinder; /** @@ -220,7 +221,7 @@ class OC_Helper { // Default check will be done with $path directories : $dirs = explode(PATH_SEPARATOR, $path); // WARNING : We have to check if open_basedir is enabled : - $obd = OC::$server->getIniWrapper()->getString('open_basedir'); + $obd = OC::$server->get(IniGetWrapper::class)->getString('open_basedir'); if ($obd != "none") { $obd_values = explode(PATH_SEPARATOR, $obd); if (count($obd_values) > 0 and $obd_values[0]) { @@ -414,7 +415,7 @@ class OC_Helper { * @return int PHP upload file size limit */ public static function uploadLimit() { - $ini = \OC::$server->getIniWrapper(); + $ini = \OC::$server->get(IniGetWrapper::class); $upload_max_filesize = OCP\Util::computerFileSize($ini->get('upload_max_filesize')); $post_max_size = OCP\Util::computerFileSize($ini->get('post_max_size')); if ((int)$upload_max_filesize === 0 and (int)$post_max_size === 0) { @@ -436,7 +437,7 @@ class OC_Helper { if (!function_exists($function_name)) { return false; } - $ini = \OC::$server->getIniWrapper(); + $ini = \OC::$server->get(IniGetWrapper::class); $disabled = explode(',', $ini->get('disable_functions') ?: ''); $disabled = array_map('trim', $disabled); if (in_array($function_name, $disabled)) { diff --git a/lib/private/legacy/OC_Util.php b/lib/private/legacy/OC_Util.php index f2aa0545af..caae862ad4 100644 --- a/lib/private/legacy/OC_Util.php +++ b/lib/private/legacy/OC_Util.php @@ -62,6 +62,7 @@ * */ +use bantu\IniGetWrapper\IniGetWrapper; use OC\AppFramework\Http\Request; use OC\Files\Storage\LocalRootStorage; use OCP\IConfig; @@ -738,7 +739,7 @@ class OC_Util { $webServerRestart = false; $setup = new \OC\Setup( $config, - \OC::$server->getIniWrapper(), + \OC::$server->get(IniGetWrapper::class), \OC::$server->getL10N('lib'), \OC::$server->query(\OCP\Defaults::class), \OC::$server->getLogger(), @@ -863,7 +864,7 @@ class OC_Util { $missingDependencies = []; $invalidIniSettings = []; - $iniWrapper = \OC::$server->getIniWrapper(); + $iniWrapper = \OC::$server->get(IniGetWrapper::class); foreach ($dependencies['classes'] as $class => $module) { if (!class_exists($class)) { $missingDependencies[] = $module; diff --git a/tests/lib/LargeFileHelperGetFileSizeTest.php b/tests/lib/LargeFileHelperGetFileSizeTest.php index 3ad8f5b880..e21ac4ee64 100644 --- a/tests/lib/LargeFileHelperGetFileSizeTest.php +++ b/tests/lib/LargeFileHelperGetFileSizeTest.php @@ -8,6 +8,8 @@ namespace Test; +use bantu\IniGetWrapper\IniGetWrapper; + /** * Tests whether LargeFileHelper is able to determine file size at all. * Large files are not considered yet. @@ -43,7 +45,7 @@ class LargeFileHelperGetFileSizeTest extends TestCase { 'The PHP curl extension is required for this test.' ); } - if (\OC::$server->getIniWrapper()->getString('open_basedir') !== '') { + if (\OC::$server->get(IniGetWrapper::class)->getString('open_basedir') !== '') { $this->markTestSkipped( 'The PHP curl extension does not work with the file:// protocol when open_basedir is enabled.' ); From 567e99abe29024742c168d85d3ce0f5030f7c7a2 Mon Sep 17 00:00:00 2001 From: Morris Jobke Date: Thu, 20 Aug 2020 14:31:16 +0200 Subject: [PATCH 2/4] Use the DI container also for the Install command registration Signed-off-by: Morris Jobke --- core/register_command.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/register_command.php b/core/register_command.php index c2a3f76b6c..98f453bca5 100644 --- a/core/register_command.php +++ b/core/register_command.php @@ -179,5 +179,5 @@ if (\OC::$server->getConfig()->getSystemValue('installed', false)) { $application->add(new OC\Core\Command\Security\RemoveCertificate(\OC::$server->getCertificateManager(null))); $application->add(new OC\Core\Command\Security\ResetBruteforceAttempts(\OC::$server->getBruteForceThrottler())); } else { - $application->add(new OC\Core\Command\Maintenance\Install(\OC::$server->getSystemConfig())); + $application->add(\OC::$server->get(\OC\Core\Command\Maintenance\Install::class)); } From 9e483ea9495288cd8d38d4d3570da6fd53e3970c Mon Sep 17 00:00:00 2001 From: Morris Jobke Date: Thu, 20 Aug 2020 16:35:14 +0200 Subject: [PATCH 3/4] Fix unit tests Signed-off-by: Morris Jobke --- .../Controller/CheckSetupControllerTest.php | 13 +++++++-- tests/lib/TempManagerTest.php | 27 +++++++------------ 2 files changed, 21 insertions(+), 19 deletions(-) diff --git a/apps/settings/tests/Controller/CheckSetupControllerTest.php b/apps/settings/tests/Controller/CheckSetupControllerTest.php index a1f7e8aa83..0bfecd05b9 100644 --- a/apps/settings/tests/Controller/CheckSetupControllerTest.php +++ b/apps/settings/tests/Controller/CheckSetupControllerTest.php @@ -35,6 +35,7 @@ namespace OCA\Settings\Tests\Controller; +use bantu\IniGetWrapper\IniGetWrapper; use OC; use OC\DB\Connection; use OC\IntegrityCheck\Checker; @@ -93,6 +94,8 @@ class CheckSetupControllerTest extends TestCase { private $memoryInfo; /** @var SecureRandom|\PHPUnit\Framework\MockObject\MockObject */ private $secureRandom; + /** @var IniGetWrapper|\PHPUnit\Framework\MockObject\MockObject */ + private $iniGetWrapper; /** * Holds a list of directories created during tests. @@ -132,6 +135,7 @@ class CheckSetupControllerTest extends TestCase { ->setMethods(['isMemoryLimitSufficient',]) ->getMock(); $this->secureRandom = $this->getMockBuilder(SecureRandom::class)->getMock(); + $this->iniGetWrapper = $this->getMockBuilder(IniGetWrapper::class)->getMock(); $this->checkSetupController = $this->getMockBuilder(CheckSetupController::class) ->setConstructorArgs([ 'settings', @@ -148,6 +152,7 @@ class CheckSetupControllerTest extends TestCase { $this->dateTimeFormatter, $this->memoryInfo, $this->secureRandom, + $this->iniGetWrapper, ]) ->setMethods([ 'isReadOnlyConfig', @@ -618,6 +623,7 @@ class CheckSetupControllerTest extends TestCase { $this->dateTimeFormatter, $this->memoryInfo, $this->secureRandom, + $this->iniGetWrapper, ]) ->setMethods(null)->getMock(); @@ -651,6 +657,7 @@ class CheckSetupControllerTest extends TestCase { $this->dateTimeFormatter, $this->memoryInfo, $this->secureRandom, + $this->iniGetWrapper, ]) ->setMethods(null)->getMock(); @@ -1418,7 +1425,8 @@ Array $this->lockingProvider, $this->dateTimeFormatter, $this->memoryInfo, - $this->secureRandom + $this->secureRandom, + $this->iniGetWrapper ); $this->assertSame($expected, $this->invokePrivate($checkSetupController, 'isMysqlUsedWithoutUTF8MB4')); @@ -1466,7 +1474,8 @@ Array $this->lockingProvider, $this->dateTimeFormatter, $this->memoryInfo, - $this->secureRandom + $this->secureRandom, + $this->iniGetWrapper ); $this->assertSame($expected, $this->invokePrivate($checkSetupController, 'isEnoughTempSpaceAvailableIfS3PrimaryStorageIsUsed')); diff --git a/tests/lib/TempManagerTest.php b/tests/lib/TempManagerTest.php index a1b5e732b4..8ae67fb1a9 100644 --- a/tests/lib/TempManagerTest.php +++ b/tests/lib/TempManagerTest.php @@ -9,18 +9,10 @@ namespace Test; +use bantu\IniGetWrapper\IniGetWrapper; use OC\Log; use OCP\IConfig; - -class NullLogger extends Log { - public function __construct($logger = null) { - //disable original constructor - } - - public function log(int $level, string $message, array $context = []) { - //noop - } -} +use Psr\Log\LoggerInterface; class TempManagerTest extends \Test\TestCase { protected $baseDir = null; @@ -47,7 +39,7 @@ class TempManagerTest extends \Test\TestCase { */ protected function getManager($logger = null, $config = null) { if (!$logger) { - $logger = new NullLogger(); + $logger = $this->createMock(LoggerInterface::class); } if (!$config) { $config = $this->createMock(IConfig::class); @@ -55,7 +47,8 @@ class TempManagerTest extends \Test\TestCase { ->with('tempdirectory', null) ->willReturn('/tmp'); } - $manager = new \OC\TempManager($logger, $config); + $iniGetWrapper = $this->createMock(IniGetWrapper::class); + $manager = new \OC\TempManager($logger, $config, $iniGetWrapper); if ($this->baseDir) { $manager->overrideTempBaseDir($this->baseDir); } @@ -140,7 +133,7 @@ class TempManagerTest extends \Test\TestCase { public function testLogCantCreateFile() { $this->markTestSkipped('TODO: Disable because fails on drone'); - $logger = $this->createMock(NullLogger::class); + $logger = $this->createMock(LoggerInterface::class); $manager = $this->getManager($logger); chmod($this->baseDir, 0500); $logger->expects($this->once()) @@ -152,7 +145,7 @@ class TempManagerTest extends \Test\TestCase { public function testLogCantCreateFolder() { $this->markTestSkipped('TODO: Disable because fails on drone'); - $logger = $this->createMock(NullLogger::class); + $logger = $this->createMock(LoggerInterface::class); $manager = $this->getManager($logger); chmod($this->baseDir, 0500); $logger->expects($this->once()) @@ -162,7 +155,7 @@ class TempManagerTest extends \Test\TestCase { } public function testBuildFileNameWithPostfix() { - $logger = $this->createMock(NullLogger::class); + $logger = $this->createMock(LoggerInterface::class); $tmpManager = self::invokePrivate( $this->getManager($logger), 'buildFileNameWithSuffix', @@ -173,7 +166,7 @@ class TempManagerTest extends \Test\TestCase { } public function testBuildFileNameWithoutPostfix() { - $logger = $this->createMock(NullLogger::class); + $logger = $this->createMock(LoggerInterface::class); $tmpManager = self::invokePrivate( $this->getManager($logger), 'buildFileNameWithSuffix', @@ -184,7 +177,7 @@ class TempManagerTest extends \Test\TestCase { } public function testBuildFileNameWithSuffixPathTraversal() { - $logger = $this->createMock(NullLogger::class); + $logger = $this->createMock(LoggerInterface::class); $tmpManager = self::invokePrivate( $this->getManager($logger), 'buildFileNameWithSuffix', From 590d46121097d8b7dcd6f722b95f9dc4bdee653e Mon Sep 17 00:00:00 2001 From: Morris Jobke Date: Thu, 20 Aug 2020 16:53:34 +0200 Subject: [PATCH 4/4] Remove unneeded import Signed-off-by: Morris Jobke --- tests/lib/TempManagerTest.php | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/lib/TempManagerTest.php b/tests/lib/TempManagerTest.php index 8ae67fb1a9..5df0e68d4f 100644 --- a/tests/lib/TempManagerTest.php +++ b/tests/lib/TempManagerTest.php @@ -10,7 +10,6 @@ namespace Test; use bantu\IniGetWrapper\IniGetWrapper; -use OC\Log; use OCP\IConfig; use Psr\Log\LoggerInterface;