aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/accessibility/lib/Controller/ConfigController.php1
-rw-r--r--apps/cloud_federation_api/lib/Config.php2
-rw-r--r--apps/comments/lib/Controller/Notifications.php1
-rw-r--r--apps/comments/tests/Unit/Collaboration/CommentersSorterTest.php1
-rw-r--r--apps/contactsinteraction/lib/AppInfo/Application.php5
-rw-r--r--apps/dav/lib/CalDAV/Activity/Provider/Event.php1
-rw-r--r--apps/dav/lib/CalDAV/Calendar.php1
-rw-r--r--apps/dav/lib/CalDAV/Integration/ICalendarProvider.php1
-rw-r--r--apps/dav/lib/CalDAV/ResourceBooking/AbstractPrincipalBackend.php1
-rw-r--r--apps/dav/lib/CalDAV/WebcalCaching/RefreshWebcalService.php1
-rw-r--r--apps/dav/lib/CardDAV/Integration/IAddressBookProvider.php1
-rw-r--r--apps/dav/lib/Command/ListCalendars.php6
-rw-r--r--apps/dav/lib/Command/MoveCalendar.php3
-rw-r--r--apps/dav/lib/Connector/Sabre/Node.php1
-rw-r--r--apps/dav/lib/Connector/Sabre/Principal.php2
-rw-r--r--apps/dav/lib/Connector/Sabre/QuotaPlugin.php1
-rw-r--r--apps/dav/lib/Connector/Sabre/ShareeList.php2
-rw-r--r--apps/dav/lib/DAV/CustomPropertiesBackend.php3
-rw-r--r--apps/dav/lib/Migration/Version1011Date20190725113607.php1
-rw-r--r--apps/dav/lib/Upload/UploadFolder.php2
-rw-r--r--apps/dav/tests/unit/CalDAV/CachedSubscriptionObjectTest.php2
-rw-r--r--apps/dav/tests/unit/CalDAV/CalendarHomeTest.php1
-rw-r--r--apps/dav/tests/unit/CalDAV/Reminder/BackendTest.php1
-rw-r--r--apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/EmailProviderTest.php2
-rw-r--r--apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/PushProviderTest.php2
-rw-r--r--apps/dav/tests/unit/CalDAV/Reminder/ReminderServiceTest.php4
-rw-r--r--apps/dav/tests/unit/CalDAV/ResourceBooking/AbstractPrincipalBackendTest.php1
-rw-r--r--apps/dav/tests/unit/CalDAV/Schedule/IMipPluginTest.php1
-rw-r--r--apps/dav/tests/unit/CardDAV/CardDavBackendTest.php1
-rw-r--r--apps/dav/tests/unit/CardDAV/ConverterTest.php1
-rw-r--r--apps/dav/tests/unit/Command/ListCalendarsTest.php1
-rw-r--r--apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php4
-rw-r--r--apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php1
-rw-r--r--apps/dav/tests/unit/Controller/InvitationResponseControllerTest.php1
-rw-r--r--apps/dav/tests/unit/DAV/CustomPropertiesBackendTest.php3
-rw-r--r--apps/dav/tests/unit/Files/FileSearchBackendTest.php3
-rw-r--r--apps/dav/tests/unit/ServerTest.php1
-rw-r--r--apps/encryption/lib/Command/RecoverUser.php5
-rw-r--r--apps/encryption/tests/RecoveryTest.php2
-rw-r--r--apps/federatedfilesharing/lib/Controller/MountPublicLinkController.php5
-rw-r--r--apps/federatedfilesharing/tests/Controller/RequestHandlerControllerTest.php9
-rw-r--r--apps/files/lib/Capabilities.php6
-rw-r--r--apps/files/lib/Controller/ApiController.php1
-rw-r--r--apps/files/lib/Controller/DirectEditingController.php3
-rw-r--r--apps/files/lib/Notification/Notifier.php2
-rw-r--r--apps/files/tests/HelperTest.php1
-rw-r--r--apps/files_external/3rdparty/icewind/smb/src/Wrapped/Share.php3
-rw-r--r--apps/files_external/lib/AppInfo/Application.php2
-rw-r--r--apps/files_external/lib/Lib/Backend/InvalidBackend.php1
-rw-r--r--apps/files_external/lib/Lib/Backend/Swift.php1
-rw-r--r--apps/files_external/lib/Migration/StorageMigrator.php1
-rw-r--r--apps/files_external/tests/Controller/GlobalStoragesControllerTest.php1
-rw-r--r--apps/files_sharing/lib/Controller/PublicPreviewController.php1
-rw-r--r--apps/files_sharing/lib/Controller/ShareesAPIController.php1
-rw-r--r--apps/files_sharing/lib/Helper.php3
-rw-r--r--apps/files_sharing/lib/Hooks.php1
-rw-r--r--apps/files_sharing/lib/Middleware/SharingCheckMiddleware.php1
-rw-r--r--apps/files_sharing/tests/TestCase.php1
-rw-r--r--apps/files_trashbin/lib/AppInfo/Application.php1
-rw-r--r--apps/files_trashbin/lib/Sabre/AbstractTrash.php1
-rw-r--r--apps/files_trashbin/lib/Sabre/PropfindPlugin.php1
-rw-r--r--apps/files_trashbin/lib/Storage.php1
-rw-r--r--apps/files_trashbin/lib/Trash/ITrashBackend.php2
-rw-r--r--apps/files_trashbin/lib/Trash/TrashManager.php2
-rw-r--r--apps/files_trashbin/tests/TrashbinTest.php1
-rw-r--r--apps/files_versions/lib/BackgroundJob/ExpireVersions.php1
-rw-r--r--apps/files_versions/lib/Sabre/RestoreFolder.php1
-rw-r--r--apps/files_versions/lib/Sabre/VersionCollection.php1
-rw-r--r--apps/files_versions/lib/Versions/IVersionBackend.php1
-rw-r--r--apps/files_versions/tests/Controller/PreviewControllerTest.php1
-rw-r--r--apps/files_versions/tests/VersioningTest.php1
-rw-r--r--apps/settings/lib/AppInfo/Application.php6
-rw-r--r--apps/settings/lib/Controller/AuthSettingsController.php1
-rw-r--r--apps/settings/lib/Controller/UsersController.php1
-rw-r--r--apps/settings/lib/Mailer/NewUserMailHelper.php1
-rw-r--r--apps/settings/lib/Settings/Admin/Sharing.php1
-rw-r--r--apps/settings/tests/Mailer/NewUserMailHelperTest.php1
-rw-r--r--apps/theming/lib/Controller/ThemingController.php2
-rw-r--r--apps/theming/tests/Controller/IconControllerTest.php1
-rw-r--r--apps/theming/tests/Controller/ThemingControllerTest.php3
-rw-r--r--apps/theming/tests/ImageManagerTest.php1
-rw-r--r--apps/theming/tests/ThemingDefaultsTest.php1
-rw-r--r--apps/theming/tests/UtilTest.php1
-rw-r--r--apps/twofactor_backupcodes/lib/AppInfo/Application.php1
-rw-r--r--apps/twofactor_backupcodes/lib/Db/BackupCodeMapper.php1
-rw-r--r--apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php4
-rw-r--r--apps/updatenotification/lib/Settings/Admin.php1
-rw-r--r--apps/updatenotification/tests/Settings/AdminTest.php1
-rw-r--r--apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserCleanUp.php1
-rw-r--r--apps/user_ldap/tests/Jobs/SyncTest.php1
-rw-r--r--apps/user_ldap/tests/Settings/AdminTest.php1
-rw-r--r--apps/user_ldap/tests/User_ProxyTest.php1
-rw-r--r--apps/workflowengine/lib/Check/FileSize.php1
-rw-r--r--build/integration/features/bootstrap/CapabilitiesContext.php4
-rw-r--r--build/integration/features/bootstrap/Download.php2
-rw-r--r--build/integration/features/bootstrap/FederationContext.php2
-rw-r--r--build/integration/features/bootstrap/FilesDropContext.php1
-rw-r--r--build/integration/features/bootstrap/ShareesContext.php2
-rw-r--r--build/integration/features/bootstrap/SharingContext.php2
-rw-r--r--core/Application.php1
-rw-r--r--core/Command/App/CheckCode.php1
-rw-r--r--core/Command/TwoFactorAuth/Disable.php1
-rw-r--r--core/Controller/CssController.php1
-rw-r--r--core/Controller/RecommendedAppsController.php1
-rw-r--r--core/Controller/SetupController.php1
-rw-r--r--core/Migrations/Version15000Date20181015062942.php1
-rw-r--r--core/Migrations/Version18000Date20191204114856.php1
-rw-r--r--lib/private/App/AppStore/Fetcher/AppFetcher.php1
-rw-r--r--lib/private/App/AppStore/Fetcher/Fetcher.php1
-rw-r--r--lib/private/App/CodeChecker/InfoChecker.php2
-rw-r--r--lib/private/App/DependencyAnalyzer.php1
-rw-r--r--lib/private/AppFramework/Middleware/PublicShare/PublicShareMiddleware.php1
-rw-r--r--lib/private/AppFramework/Middleware/Security/FeaturePolicyMiddleware.php5
-rw-r--r--lib/private/AppFramework/Middleware/SessionMiddleware.php1
-rw-r--r--lib/private/AppFramework/OCS/BaseResponse.php1
-rw-r--r--lib/private/Authentication/Events/ARemoteWipeEvent.php1
-rw-r--r--lib/private/Authentication/Listeners/RemoteWipeActivityListener.php1
-rw-r--r--lib/private/Authentication/Listeners/RemoteWipeNotificationsListener.php1
-rw-r--r--lib/private/Authentication/Token/RemoteWipe.php1
-rw-r--r--lib/private/Authentication/TwoFactorAuth/Manager.php2
-rw-r--r--lib/private/Authentication/TwoFactorAuth/ProviderManager.php1
-rw-r--r--lib/private/Collaboration/Resources/Manager.php1
-rw-r--r--lib/private/DB/AdapterPgSql.php1
-rw-r--r--lib/private/DB/Connection.php1
-rw-r--r--lib/private/DirectEditing/Manager.php2
-rw-r--r--lib/private/Files/Filesystem.php1
-rw-r--r--lib/private/Files/Type/Loader.php1
-rw-r--r--lib/private/Lock/DBLockingProvider.php1
-rw-r--r--lib/private/Log/Systemdlog.php1
-rw-r--r--lib/private/Preview/Generator.php2
-rw-r--r--lib/private/Preview/GeneratorHelper.php1
-rw-r--r--lib/private/Session/Internal.php2
-rw-r--r--lib/private/Settings/Manager.php1
-rw-r--r--lib/private/Setup.php1
-rw-r--r--lib/private/Share/Share.php2
-rw-r--r--lib/private/Share20/DefaultShareProvider.php1
-rw-r--r--lib/private/Share20/ProviderFactory.php1
-rw-r--r--lib/private/User/Database.php1
-rw-r--r--lib/private/legacy/files.php1
-rw-r--r--lib/public/AppFramework/Http/Template/ExternalShareMenuAction.php1
-rw-r--r--lib/public/AppFramework/Http/Template/LinkMenuAction.php1
-rw-r--r--lib/public/Group/Events/BeforeGroupCreatedEvent.php1
-rw-r--r--lib/public/IUser.php1
-rw-r--r--lib/public/Share/IProviderFactory.php1
-rw-r--r--lib/public/User/Events/BeforeUserLoggedInWithCookieEvent.php1
-rw-r--r--tests/Core/Command/Maintenance/UpdateTheme.php3
-rw-r--r--tests/Core/Controller/OCSControllerTest.php1
-rw-r--r--tests/acceptance/features/bootstrap/FileListAncestorSetter.php1
-rw-r--r--tests/lib/App/CodeChecker/InfoCheckerTest.php1
-rw-r--r--tests/lib/AppFramework/Controller/AuthPublicShareControllerTest.php7
-rw-r--r--tests/lib/AppFramework/Controller/ControllerTest.php1
-rw-r--r--tests/lib/AppFramework/Controller/PublicShareControllerTest.php9
-rw-r--r--tests/lib/AppFramework/Http/ContentSecurityPolicyTest.php1
-rw-r--r--tests/lib/AppFramework/Http/EmptyContentSecurityPolicyTest.php1
-rw-r--r--tests/lib/AppFramework/Middleware/MiddlewareDispatcherTest.php1
-rw-r--r--tests/lib/AppFramework/Middleware/Security/BruteForceMiddlewareTest.php1
-rw-r--r--tests/lib/AppFramework/Middleware/Security/FeaturePolicyMiddlewareTest.php3
-rw-r--r--tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php7
-rw-r--r--tests/lib/AppFramework/Middleware/SessionMiddlewareTest.php2
-rw-r--r--tests/lib/Authentication/Listeners/RemoteWipeActivityListenerTest.php1
-rw-r--r--tests/lib/Authentication/Login/ClearLostPasswordTokensCommandTest.php1
-rw-r--r--tests/lib/Authentication/Login/UidLoginCommandTest.php1
-rw-r--r--tests/lib/Authentication/Token/ManagerTest.php1
-rw-r--r--tests/lib/Authentication/TwoFactorAuth/ManagerTest.php1
-rw-r--r--tests/lib/Authentication/TwoFactorAuth/ProviderLoaderTest.php1
-rw-r--r--tests/lib/Collaboration/Collaborators/SearchResultTest.php2
-rw-r--r--tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php1
-rw-r--r--tests/lib/DirectEditing/ManagerTest.php1
-rw-r--r--tests/lib/Encryption/DecryptAllTest.php1
-rw-r--r--tests/lib/Files/Cache/UpdaterLegacyTest.php1
-rw-r--r--tests/lib/Files/Cache/UpdaterTest.php1
-rw-r--r--tests/lib/Files/EtagTest.php1
-rw-r--r--tests/lib/Files/FileInfoTest.php2
-rw-r--r--tests/lib/Files/Node/FolderTest.php1
-rw-r--r--tests/lib/Files/Node/NodeTest.php3
-rw-r--r--tests/lib/Files/Node/RootTest.php2
-rw-r--r--tests/lib/Files/ObjectStore/ObjectStoreStorageTest.php1
-rw-r--r--tests/lib/Files/SimpleFS/SimpleFileTest.php1
-rw-r--r--tests/lib/Files/SimpleFS/SimpleFolderTest.php3
-rw-r--r--tests/lib/Group/GroupTest.php2
-rw-r--r--tests/lib/InstallerTest.php1
-rw-r--r--tests/lib/Log/LogFactoryTest.php1
-rw-r--r--tests/lib/Mail/MailerTest.php1
-rw-r--r--tests/lib/Notification/ManagerTest.php2
-rw-r--r--tests/lib/Preview/BackgroundCleanupJobTest.php1
-rw-r--r--tests/lib/Preview/GeneratorTest.php1
-rw-r--r--tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php2
-rw-r--r--tests/lib/Security/CertificateManagerTest.php1
-rw-r--r--tests/lib/Security/FeaturePolicy/FeaturePolicyManagerTest.php4
-rw-r--r--tests/lib/Security/IdentityProof/ManagerTest.php1
-rw-r--r--tests/lib/Security/RateLimiting/LimiterTest.php3
-rw-r--r--tests/lib/Settings/ManagerTest.php1
-rw-r--r--tests/lib/Share/ShareTest.php1
-rw-r--r--tests/lib/SystemTag/SystemTagManagerTest.php1
-rw-r--r--tests/lib/Template/IconsCacherTest.php6
-rw-r--r--tests/lib/Template/JSCombinerTest.php1
-rw-r--r--tests/lib/Template/SCSSCacherTest.php1
197 files changed, 0 insertions, 332 deletions
diff --git a/apps/accessibility/lib/Controller/ConfigController.php b/apps/accessibility/lib/Controller/ConfigController.php
index a84281501ca..750a1fbe11d 100644
--- a/apps/accessibility/lib/Controller/ConfigController.php
+++ b/apps/accessibility/lib/Controller/ConfigController.php
@@ -30,7 +30,6 @@ declare(strict_types=1);
namespace OCA\Accessibility\Controller;
use OCA\Accessibility\AccessibilityProvider;
-use OCP\AppFramework\Http;
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\OCS\OCSBadRequestException;
use OCP\AppFramework\OCSController;
diff --git a/apps/cloud_federation_api/lib/Config.php b/apps/cloud_federation_api/lib/Config.php
index 7addd27e18b..cd2b333c237 100644
--- a/apps/cloud_federation_api/lib/Config.php
+++ b/apps/cloud_federation_api/lib/Config.php
@@ -23,8 +23,6 @@
namespace OCA\CloudFederationAPI;
use OCP\Federation\ICloudFederationProviderManager;
-use OCP\GlobalScale\IConfig as IGsConfig;
-use OCP\IConfig;
/**
* Class config
diff --git a/apps/comments/lib/Controller/Notifications.php b/apps/comments/lib/Controller/Notifications.php
index eab5a842fa6..6610b56b689 100644
--- a/apps/comments/lib/Controller/Notifications.php
+++ b/apps/comments/lib/Controller/Notifications.php
@@ -30,7 +30,6 @@ use OCP\AppFramework\Http\RedirectResponse;
use OCP\AppFramework\Http\Response;
use OCP\Comments\IComment;
use OCP\Comments\ICommentsManager;
-use OCP\Files\Folder;
use OCP\Files\IRootFolder;
use OCP\IRequest;
use OCP\IURLGenerator;
diff --git a/apps/comments/tests/Unit/Collaboration/CommentersSorterTest.php b/apps/comments/tests/Unit/Collaboration/CommentersSorterTest.php
index 63d4b06b422..7223019b96a 100644
--- a/apps/comments/tests/Unit/Collaboration/CommentersSorterTest.php
+++ b/apps/comments/tests/Unit/Collaboration/CommentersSorterTest.php
@@ -28,7 +28,6 @@ namespace OCA\Comments\Tests\Unit\Collaboration;
use OCA\Comments\Collaboration\CommentersSorter;
use OCP\Comments\IComment;
use OCP\Comments\ICommentsManager;
-use OCP\IConfig;
use Test\TestCase;
class CommentersSorterTest extends TestCase {
diff --git a/apps/contactsinteraction/lib/AppInfo/Application.php b/apps/contactsinteraction/lib/AppInfo/Application.php
index 674034cbe48..3a7e0111f6c 100644
--- a/apps/contactsinteraction/lib/AppInfo/Application.php
+++ b/apps/contactsinteraction/lib/AppInfo/Application.php
@@ -25,15 +25,10 @@ declare(strict_types=1);
namespace OCA\ContactsInteraction\AppInfo;
-use OCA\ContactsInteraction\AddressBook;
use OCA\ContactsInteraction\Listeners\ContactInteractionListener;
-use OCA\ContactsInteraction\Store;
use OCP\AppFramework\App;
-use OCP\AppFramework\IAppContainer;
use OCP\Contacts\Events\ContactInteractedWithEvent;
use OCP\EventDispatcher\IEventDispatcher;
-use OCP\EventDispatcher\IEventListener;
-use OCP\IL10N;
class Application extends App {
diff --git a/apps/dav/lib/CalDAV/Activity/Provider/Event.php b/apps/dav/lib/CalDAV/Activity/Provider/Event.php
index 46e3a95d95e..c554b2b6d20 100644
--- a/apps/dav/lib/CalDAV/Activity/Provider/Event.php
+++ b/apps/dav/lib/CalDAV/Activity/Provider/Event.php
@@ -24,7 +24,6 @@
namespace OCA\DAV\CalDAV\Activity\Provider;
-use OCA\DAV\CalDAV\CalDavBackend;
use OCP\Activity\IEvent;
use OCP\Activity\IEventMerger;
use OCP\Activity\IManager;
diff --git a/apps/dav/lib/CalDAV/Calendar.php b/apps/dav/lib/CalDAV/Calendar.php
index e3147062b1a..7a460602903 100644
--- a/apps/dav/lib/CalDAV/Calendar.php
+++ b/apps/dav/lib/CalDAV/Calendar.php
@@ -27,7 +27,6 @@
namespace OCA\DAV\CalDAV;
-use OCA\DAV\CalDAV\Proxy\ProxyMapper;
use OCA\DAV\DAV\Sharing\IShareable;
use OCA\DAV\Exception\UnsupportedLimitOnInitialSyncException;
use OCP\IConfig;
diff --git a/apps/dav/lib/CalDAV/Integration/ICalendarProvider.php b/apps/dav/lib/CalDAV/Integration/ICalendarProvider.php
index 29f5f113ef5..806d0f13a03 100644
--- a/apps/dav/lib/CalDAV/Integration/ICalendarProvider.php
+++ b/apps/dav/lib/CalDAV/Integration/ICalendarProvider.php
@@ -22,7 +22,6 @@
*/
namespace OCA\DAV\CalDAV\Integration;
-use Sabre\CalDAV\ICalendar;
/**
* Interface ICalendarProvider
diff --git a/apps/dav/lib/CalDAV/ResourceBooking/AbstractPrincipalBackend.php b/apps/dav/lib/CalDAV/ResourceBooking/AbstractPrincipalBackend.php
index bad549960d9..5a25fbaa22e 100644
--- a/apps/dav/lib/CalDAV/ResourceBooking/AbstractPrincipalBackend.php
+++ b/apps/dav/lib/CalDAV/ResourceBooking/AbstractPrincipalBackend.php
@@ -30,7 +30,6 @@ use OCP\IDBConnection;
use OCP\IGroupManager;
use OCP\ILogger;
use OCP\IUserSession;
-use Sabre\DAV\Exception;
use Sabre\DAV\PropPatch;
use Sabre\DAVACL\PrincipalBackend\BackendInterface;
diff --git a/apps/dav/lib/CalDAV/WebcalCaching/RefreshWebcalService.php b/apps/dav/lib/CalDAV/WebcalCaching/RefreshWebcalService.php
index a057e29eb2c..3b53487facd 100644
--- a/apps/dav/lib/CalDAV/WebcalCaching/RefreshWebcalService.php
+++ b/apps/dav/lib/CalDAV/WebcalCaching/RefreshWebcalService.php
@@ -32,7 +32,6 @@ use Exception;
use GuzzleHttp\HandlerStack;
use GuzzleHttp\Middleware;
use OCA\DAV\CalDAV\CalDavBackend;
-use OCP\AppFramework\Utility\ITimeFactory;
use OCP\Http\Client\IClientService;
use OCP\IConfig;
use OCP\ILogger;
diff --git a/apps/dav/lib/CardDAV/Integration/IAddressBookProvider.php b/apps/dav/lib/CardDAV/Integration/IAddressBookProvider.php
index 4410a7486bf..1299d935c57 100644
--- a/apps/dav/lib/CardDAV/Integration/IAddressBookProvider.php
+++ b/apps/dav/lib/CardDAV/Integration/IAddressBookProvider.php
@@ -4,7 +4,6 @@ declare(strict_types=1);
namespace OCA\DAV\CardDAV\Integration;
-use Sabre\CardDAV\IAddressBook;
/**
* @since 19.0.0
diff --git a/apps/dav/lib/Command/ListCalendars.php b/apps/dav/lib/Command/ListCalendars.php
index fc7d123a272..768486a07eb 100644
--- a/apps/dav/lib/Command/ListCalendars.php
+++ b/apps/dav/lib/Command/ListCalendars.php
@@ -27,13 +27,7 @@ namespace OCA\DAV\Command;
use OCA\DAV\CalDAV\BirthdayService;
use OCA\DAV\CalDAV\CalDavBackend;
-use OCA\DAV\Connector\Sabre\Principal;
-use OCP\IConfig;
-use OCP\IDBConnection;
-use OCP\IGroupManager;
use OCP\IUserManager;
-use OCP\IUserSession;
-use OCP\Share\IManager;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Helper\Table;
use Symfony\Component\Console\Input\InputArgument;
diff --git a/apps/dav/lib/Command/MoveCalendar.php b/apps/dav/lib/Command/MoveCalendar.php
index 1c43190c4e2..f74a5062c2b 100644
--- a/apps/dav/lib/Command/MoveCalendar.php
+++ b/apps/dav/lib/Command/MoveCalendar.php
@@ -27,13 +27,10 @@ namespace OCA\DAV\Command;
use OCA\DAV\CalDAV\CalDavBackend;
use OCA\DAV\CalDAV\Calendar;
-use OCA\DAV\Connector\Sabre\Principal;
use OCP\IConfig;
-use OCP\IDBConnection;
use OCP\IGroupManager;
use OCP\IL10N;
use OCP\IUserManager;
-use OCP\IUserSession;
use OCP\Share\IManager as IShareManager;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Input\InputArgument;
diff --git a/apps/dav/lib/Connector/Sabre/Node.php b/apps/dav/lib/Connector/Sabre/Node.php
index f178b2fbfbd..225024a1136 100644
--- a/apps/dav/lib/Connector/Sabre/Node.php
+++ b/apps/dav/lib/Connector/Sabre/Node.php
@@ -45,7 +45,6 @@ use OCP\Files\StorageNotAvailableException;
use OCP\Share;
use OCP\Share\Exceptions\ShareNotFound;
use OCP\Share\IManager;
-use OCP\Share\IShare;
abstract class Node implements \Sabre\DAV\INode {
diff --git a/apps/dav/lib/Connector/Sabre/Principal.php b/apps/dav/lib/Connector/Sabre/Principal.php
index 41b85f162c8..6be21eda3f6 100644
--- a/apps/dav/lib/Connector/Sabre/Principal.php
+++ b/apps/dav/lib/Connector/Sabre/Principal.php
@@ -33,13 +33,11 @@
namespace OCA\DAV\Connector\Sabre;
use OCA\Circles\Exceptions\CircleDoesNotExistException;
-use OCA\DAV\CalDAV\Proxy\Proxy;
use OCA\DAV\CalDAV\Proxy\ProxyMapper;
use OCA\DAV\Traits\PrincipalProxyTrait;
use OCP\App\IAppManager;
use OCP\AppFramework\QueryException;
use OCP\IConfig;
-use OCP\IGroup;
use OCP\IGroupManager;
use OCP\IUser;
use OCP\IUserManager;
diff --git a/apps/dav/lib/Connector/Sabre/QuotaPlugin.php b/apps/dav/lib/Connector/Sabre/QuotaPlugin.php
index 305ce5154a6..39bee3a6656 100644
--- a/apps/dav/lib/Connector/Sabre/QuotaPlugin.php
+++ b/apps/dav/lib/Connector/Sabre/QuotaPlugin.php
@@ -28,7 +28,6 @@
namespace OCA\DAV\Connector\Sabre;
use OCA\DAV\Upload\FutureFile;
-use OCP\Files\FileInfo;
use OCP\Files\StorageNotAvailableException;
use Sabre\DAV\Exception\InsufficientStorage;
use Sabre\DAV\Exception\ServiceUnavailable;
diff --git a/apps/dav/lib/Connector/Sabre/ShareeList.php b/apps/dav/lib/Connector/Sabre/ShareeList.php
index 48cc0540378..67b42aad919 100644
--- a/apps/dav/lib/Connector/Sabre/ShareeList.php
+++ b/apps/dav/lib/Connector/Sabre/ShareeList.php
@@ -28,8 +28,6 @@ declare(strict_types=1);
namespace OCA\DAV\Connector\Sabre;
use OCP\Share\IShare;
-use Sabre\Xml\Element;
-use Sabre\Xml\Reader;
use Sabre\Xml\Writer;
use Sabre\Xml\XmlSerializable;
diff --git a/apps/dav/lib/DAV/CustomPropertiesBackend.php b/apps/dav/lib/DAV/CustomPropertiesBackend.php
index 8b0408a461b..81fb63dd856 100644
--- a/apps/dav/lib/DAV/CustomPropertiesBackend.php
+++ b/apps/dav/lib/DAV/CustomPropertiesBackend.php
@@ -30,9 +30,6 @@ namespace OCA\DAV\DAV;
use OCA\DAV\Connector\Sabre\Node;
use OCP\IDBConnection;
use OCP\IUser;
-use Sabre\DAV\Exception\NotFound;
-use Sabre\DAV\Exception\ServiceUnavailable;
-use Sabre\DAV\INode;
use Sabre\DAV\PropertyStorage\Backend\BackendInterface;
use Sabre\DAV\PropFind;
use Sabre\DAV\PropPatch;
diff --git a/apps/dav/lib/Migration/Version1011Date20190725113607.php b/apps/dav/lib/Migration/Version1011Date20190725113607.php
index 12796334d6b..c2604c8e274 100644
--- a/apps/dav/lib/Migration/Version1011Date20190725113607.php
+++ b/apps/dav/lib/Migration/Version1011Date20190725113607.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
*/
namespace OCA\DAV\Migration;
-use Closure;
use Doctrine\DBAL\Types\Type;
use OCP\DB\ISchemaWrapper;
use OCP\Migration\IOutput;
diff --git a/apps/dav/lib/Upload/UploadFolder.php b/apps/dav/lib/Upload/UploadFolder.php
index 737e7e0b557..6778a30b8a2 100644
--- a/apps/dav/lib/Upload/UploadFolder.php
+++ b/apps/dav/lib/Upload/UploadFolder.php
@@ -24,9 +24,7 @@
namespace OCA\DAV\Upload;
-use OCA\DAV\BackgroundJob\UploadCleanup;
use OCA\DAV\Connector\Sabre\Directory;
-use OCP\BackgroundJob\IJobList;
use Sabre\DAV\Exception\Forbidden;
use Sabre\DAV\ICollection;
diff --git a/apps/dav/tests/unit/CalDAV/CachedSubscriptionObjectTest.php b/apps/dav/tests/unit/CalDAV/CachedSubscriptionObjectTest.php
index f0357f203e2..99c4db3dfcb 100644
--- a/apps/dav/tests/unit/CalDAV/CachedSubscriptionObjectTest.php
+++ b/apps/dav/tests/unit/CalDAV/CachedSubscriptionObjectTest.php
@@ -26,8 +26,6 @@ namespace OCA\DAV\Tests\unit\CalDAV;
use OCA\DAV\CalDAV\CachedSubscriptionObject;
use OCA\DAV\CalDAV\CalDavBackend;
-use OCA\DAV\CalDAV\Calendar;
-use OCA\DAV\CalDAV\CalendarImpl;
class CachedSubscriptionObjectTest extends \Test\TestCase {
diff --git a/apps/dav/tests/unit/CalDAV/CalendarHomeTest.php b/apps/dav/tests/unit/CalDAV/CalendarHomeTest.php
index 364286edd4b..53cdad1ad6f 100644
--- a/apps/dav/tests/unit/CalDAV/CalendarHomeTest.php
+++ b/apps/dav/tests/unit/CalDAV/CalendarHomeTest.php
@@ -31,7 +31,6 @@ use OCA\DAV\CalDAV\Integration\ExternalCalendar;
use OCA\DAV\CalDAV\Integration\ICalendarProvider;
use OCA\DAV\CalDAV\Outbox;
use Sabre\CalDAV\Schedule\Inbox;
-use Sabre\DAV\Exception\NotFound;
use Sabre\DAV\MkCol;
use Test\TestCase;
diff --git a/apps/dav/tests/unit/CalDAV/Reminder/BackendTest.php b/apps/dav/tests/unit/CalDAV/Reminder/BackendTest.php
index 88300e2ffec..6a499099023 100644
--- a/apps/dav/tests/unit/CalDAV/Reminder/BackendTest.php
+++ b/apps/dav/tests/unit/CalDAV/Reminder/BackendTest.php
@@ -31,7 +31,6 @@ namespace OCA\DAV\Tests\unit\CalDAV\Reminder;
use OCA\DAV\CalDAV\Reminder\Backend as ReminderBackend;
use OCP\AppFramework\Utility\ITimeFactory;
-use OCP\DB\QueryBuilder\IQueryBuilder;
use Test\TestCase;
class BackendTest extends TestCase {
diff --git a/apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/EmailProviderTest.php b/apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/EmailProviderTest.php
index 2d04c605fcf..3b20acd6dff 100644
--- a/apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/EmailProviderTest.php
+++ b/apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/EmailProviderTest.php
@@ -36,12 +36,10 @@ use OCP\ILogger;
use OCP\IURLGenerator;
use OCP\IUser;
use OCP\L10N\IFactory as L10NFactory;
-use OCP\Mail\IAttachment;
use OCP\Mail\IEMailTemplate;
use OCP\Mail\IMailer;
use OCP\Mail\IMessage;
use Sabre\VObject\Component\VCalendar;
-use Test\TestCase;
class EmailProviderTest extends AbstractNotificationProviderTest {
diff --git a/apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/PushProviderTest.php b/apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/PushProviderTest.php
index 92ccbfb08f8..0003b5bb6b3 100644
--- a/apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/PushProviderTest.php
+++ b/apps/dav/tests/unit/CalDAV/Reminder/NotificationProvider/PushProviderTest.php
@@ -29,7 +29,6 @@ declare(strict_types=1);
namespace OCA\DAV\Tests\unit\CalDAV\Reminder\NotificationProvider;
-use OCA\DAV\AppInfo\Application;
use OCA\DAV\CalDAV\Reminder\NotificationProvider\PushProvider;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\IConfig;
@@ -40,7 +39,6 @@ use OCP\IUser;
use OCP\L10N\IFactory as L10NFactory;
use OCP\Notification\IManager;
use OCP\Notification\INotification;
-use Test\TestCase;
class PushProviderTest extends AbstractNotificationProviderTest {
diff --git a/apps/dav/tests/unit/CalDAV/Reminder/ReminderServiceTest.php b/apps/dav/tests/unit/CalDAV/Reminder/ReminderServiceTest.php
index 7e8ee32cec6..28f44fbf1c0 100644
--- a/apps/dav/tests/unit/CalDAV/Reminder/ReminderServiceTest.php
+++ b/apps/dav/tests/unit/CalDAV/Reminder/ReminderServiceTest.php
@@ -29,15 +29,11 @@ declare(strict_types=1);
namespace OCA\DAV\Tests\unit\CalDAV\Reminder;
use OCA\DAV\CalDAV\CalDavBackend;
-use OCA\DAV\CalDAV\Reminder\AbstractNotificationProvider;
use OCA\DAV\CalDAV\Reminder\Backend;
use OCA\DAV\CalDAV\Reminder\INotificationProvider;
-use OCA\DAV\CalDAV\Reminder\NotificationProvider\EmailProvider;
-use OCA\DAV\CalDAV\Reminder\NotificationProvider\PushProvider;
use OCA\DAV\CalDAV\Reminder\NotificationProviderManager;
use OCA\DAV\CalDAV\Reminder\ReminderService;
use OCP\AppFramework\Utility\ITimeFactory;
-use OCP\IGroup;
use OCP\IGroupManager;
use OCP\IUser;
use OCP\IUserManager;
diff --git a/apps/dav/tests/unit/CalDAV/ResourceBooking/AbstractPrincipalBackendTest.php b/apps/dav/tests/unit/CalDAV/ResourceBooking/AbstractPrincipalBackendTest.php
index 148e7627af6..a31968377fb 100644
--- a/apps/dav/tests/unit/CalDAV/ResourceBooking/AbstractPrincipalBackendTest.php
+++ b/apps/dav/tests/unit/CalDAV/ResourceBooking/AbstractPrincipalBackendTest.php
@@ -26,7 +26,6 @@ namespace OCA\DAV\Tests\unit\CalDAV\ResourceBooking;
use OCA\DAV\CalDAV\Proxy\Proxy;
use OCA\DAV\CalDAV\Proxy\ProxyMapper;
-use OCP\DB\QueryBuilder\IQueryBuilder;
use OCP\IGroupManager;
use OCP\ILogger;
use OCP\IUser;
diff --git a/apps/dav/tests/unit/CalDAV/Schedule/IMipPluginTest.php b/apps/dav/tests/unit/CalDAV/Schedule/IMipPluginTest.php
index b1da96f4c03..7b65009cb36 100644
--- a/apps/dav/tests/unit/CalDAV/Schedule/IMipPluginTest.php
+++ b/apps/dav/tests/unit/CalDAV/Schedule/IMipPluginTest.php
@@ -28,7 +28,6 @@
namespace OCA\DAV\Tests\unit\CalDAV\Schedule;
-use OC\Mail\Mailer;
use OCA\DAV\CalDAV\Schedule\IMipPlugin;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\DB\QueryBuilder\IQueryBuilder;
diff --git a/apps/dav/tests/unit/CardDAV/CardDavBackendTest.php b/apps/dav/tests/unit/CardDAV/CardDavBackendTest.php
index 251ce88457b..9298edb53ad 100644
--- a/apps/dav/tests/unit/CardDAV/CardDavBackendTest.php
+++ b/apps/dav/tests/unit/CardDAV/CardDavBackendTest.php
@@ -32,7 +32,6 @@
namespace OCA\DAV\Tests\unit\CardDAV;
-use InvalidArgumentException;
use OCA\DAV\CalDAV\Proxy\ProxyMapper;
use OCA\DAV\CardDAV\AddressBook;
use OCA\DAV\CardDAV\CardDavBackend;
diff --git a/apps/dav/tests/unit/CardDAV/ConverterTest.php b/apps/dav/tests/unit/CardDAV/ConverterTest.php
index 110e8ad7bf8..0c129b0de7d 100644
--- a/apps/dav/tests/unit/CardDAV/ConverterTest.php
+++ b/apps/dav/tests/unit/CardDAV/ConverterTest.php
@@ -29,7 +29,6 @@ namespace OCA\DAV\Tests\unit\CardDAV;
use OC\Accounts\AccountManager;
use OCA\DAV\CardDAV\Converter;
-use OCP\IDBConnection;
use OCP\IImage;
use OCP\IUser;
use PHPUnit_Framework_MockObject_MockObject;
diff --git a/apps/dav/tests/unit/Command/ListCalendarsTest.php b/apps/dav/tests/unit/Command/ListCalendarsTest.php
index 42e24be5cd3..7d2fdc6b157 100644
--- a/apps/dav/tests/unit/Command/ListCalendarsTest.php
+++ b/apps/dav/tests/unit/Command/ListCalendarsTest.php
@@ -25,7 +25,6 @@
namespace OCA\DAV\Tests\Command;
-use InvalidArgumentException;
use OCA\DAV\CalDAV\BirthdayService;
use OCA\DAV\CalDAV\CalDavBackend;
use OCA\DAV\Command\ListCalendars;
diff --git a/apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php
index 56ad3b36f73..c1acc22f136 100644
--- a/apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php
+++ b/apps/dav/tests/unit/Connector/Sabre/QuotaPluginTest.php
@@ -27,12 +27,8 @@
namespace OCA\DAV\Tests\unit\Connector\Sabre;
use OC\Files\View;
-use OCA\DAV\Connector\Sabre\Directory;
use OCA\DAV\Connector\Sabre\QuotaPlugin;
-use OCA\DAV\Files\FilesHome;
use OCP\Files\FileInfo;
-use Sabre\DAV\Exception\InsufficientStorage;
-use Sabre\DAV\Tree;
use Test\TestCase;
/**
diff --git a/apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php b/apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php
index 3769399b624..07396f6f535 100644
--- a/apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php
+++ b/apps/dav/tests/unit/Connector/Sabre/RequestTest/UploadTest.php
@@ -25,7 +25,6 @@
namespace OCA\DAV\Tests\unit\Connector\Sabre\RequestTest;
-use OC\Connector\Sabre\Exception\FileLocked;
use OCP\AppFramework\Http;
use OCP\Lock\ILockingProvider;
diff --git a/apps/dav/tests/unit/Controller/InvitationResponseControllerTest.php b/apps/dav/tests/unit/Controller/InvitationResponseControllerTest.php
index 811c4cac283..a6b89b2137c 100644
--- a/apps/dav/tests/unit/Controller/InvitationResponseControllerTest.php
+++ b/apps/dav/tests/unit/Controller/InvitationResponseControllerTest.php
@@ -29,7 +29,6 @@ declare(strict_types=1);
namespace OCA\DAV\Tests\Unit\DAV\Controller;
use OCA\DAV\CalDAV\InvitationResponse\InvitationResponseServer;
-use OCA\DAV\CalDAV\Schedule\Plugin;
use OCA\DAV\Controller\InvitationResponseController;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\AppFramework\Utility\ITimeFactory;
diff --git a/apps/dav/tests/unit/DAV/CustomPropertiesBackendTest.php b/apps/dav/tests/unit/DAV/CustomPropertiesBackendTest.php
index 45aab9af1f5..ea3f2e51b07 100644
--- a/apps/dav/tests/unit/DAV/CustomPropertiesBackendTest.php
+++ b/apps/dav/tests/unit/DAV/CustomPropertiesBackendTest.php
@@ -24,12 +24,9 @@
namespace OCA\DAV\Tests\DAV;
-use OCA\DAV\Connector\Sabre\Node;
use OCA\DAV\DAV\CustomPropertiesBackend;
use OCP\IDBConnection;
use OCP\IUser;
-use Sabre\DAV\Exception\NotFound;
-use Sabre\DAV\INode;
use Sabre\DAV\PropFind;
use Sabre\DAV\PropPatch;
use Sabre\DAV\Tree;
diff --git a/apps/dav/tests/unit/Files/FileSearchBackendTest.php b/apps/dav/tests/unit/Files/FileSearchBackendTest.php
index 2f8dec62480..7d06eecea89 100644
--- a/apps/dav/tests/unit/Files/FileSearchBackendTest.php
+++ b/apps/dav/tests/unit/Files/FileSearchBackendTest.php
@@ -43,10 +43,7 @@ use OCP\Share\IManager;
use SearchDAV\Backend\SearchPropertyDefinition;
use SearchDAV\Query\Limit;
use SearchDAV\Query\Query;
-use SearchDAV\XML\BasicSearch;
-use SearchDAV\XML\Literal;
use SearchDAV\XML\Operator;
-use SearchDAV\XML\Scope;
use Test\TestCase;
class FileSearchBackendTest extends TestCase {
diff --git a/apps/dav/tests/unit/ServerTest.php b/apps/dav/tests/unit/ServerTest.php
index a880e898479..c9bdb2627c5 100644
--- a/apps/dav/tests/unit/ServerTest.php
+++ b/apps/dav/tests/unit/ServerTest.php
@@ -26,7 +26,6 @@
namespace OCA\DAV\Tests\unit;
-use OCA\DAV\AppInfo\PluginManager;
use OCA\DAV\Server;
use OCP\IRequest;
diff --git a/apps/encryption/lib/Command/RecoverUser.php b/apps/encryption/lib/Command/RecoverUser.php
index 5d7909a3e98..fee9195cf1e 100644
--- a/apps/encryption/lib/Command/RecoverUser.php
+++ b/apps/encryption/lib/Command/RecoverUser.php
@@ -24,11 +24,6 @@
namespace OCA\Encryption\Command;
-use OC\Files\Filesystem;
-use OC\User\NoUserException;
-use OCA\Encryption\Crypto\Crypt;
-use OCA\Encryption\KeyManager;
-use OCA\Encryption\Recovery;
use OCA\Encryption\Util;
use OCP\IConfig;
use OCP\IUserManager;
diff --git a/apps/encryption/tests/RecoveryTest.php b/apps/encryption/tests/RecoveryTest.php
index a76d5f7d562..b9490342707 100644
--- a/apps/encryption/tests/RecoveryTest.php
+++ b/apps/encryption/tests/RecoveryTest.php
@@ -33,11 +33,9 @@ use OCA\Encryption\Crypto\Crypt;
use OCA\Encryption\KeyManager;
use OCA\Encryption\Recovery;
use OCP\Encryption\IFile;
-use OCP\Encryption\Keys\IStorage;
use OCP\IConfig;
use OCP\IUser;
use OCP\IUserSession;
-use OCP\Security\ISecureRandom;
use PHPUnit\Framework\MockObject\MockObject;
use Test\TestCase;
diff --git a/apps/federatedfilesharing/lib/Controller/MountPublicLinkController.php b/apps/federatedfilesharing/lib/Controller/MountPublicLinkController.php
index c0c9ce9bc8c..bf2948b0f64 100644
--- a/apps/federatedfilesharing/lib/Controller/MountPublicLinkController.php
+++ b/apps/federatedfilesharing/lib/Controller/MountPublicLinkController.php
@@ -29,17 +29,13 @@
namespace OCA\FederatedFileSharing\Controller;
-use OC\Files\Filesystem;
use OC\HintException;
-use OC\Share\Helper;
use OCA\FederatedFileSharing\AddressHandler;
use OCA\FederatedFileSharing\FederatedShareProvider;
-use OCA\Files_Sharing\External\Manager;
use OCP\AppFramework\Controller;
use OCP\AppFramework\Http;
use OCP\AppFramework\Http\JSONResponse;
use OCP\Federation\ICloudIdManager;
-use OCP\Files\StorageInvalidException;
use OCP\Http\Client\IClientService;
use OCP\IL10N;
use OCP\ILogger;
@@ -47,7 +43,6 @@ use OCP\IRequest;
use OCP\ISession;
use OCP\IUserSession;
use OCP\Share\IManager;
-use OCP\Util;
/**
* Class MountPublicLinkController
diff --git a/apps/federatedfilesharing/tests/Controller/RequestHandlerControllerTest.php b/apps/federatedfilesharing/tests/Controller/RequestHandlerControllerTest.php
index 805b79f4396..a99dfb55801 100644
--- a/apps/federatedfilesharing/tests/Controller/RequestHandlerControllerTest.php
+++ b/apps/federatedfilesharing/tests/Controller/RequestHandlerControllerTest.php
@@ -28,28 +28,19 @@
namespace OCA\FederatedFileSharing\Tests;
-use OC\AppFramework\Http;
-use OC\Federation\CloudIdManager;
-use OC\Files\Filesystem;
use OCA\FederatedFileSharing\Controller\RequestHandlerController;
-use OCA\FederatedFileSharing\FederatedShareProvider;
use OCP\AppFramework\Http\DataResponse;
use OCP\Federation\ICloudFederationFactory;
use OCP\Federation\ICloudFederationProvider;
use OCP\Federation\ICloudFederationProviderManager;
use OCP\Federation\ICloudFederationShare;
use OCP\Federation\ICloudIdManager;
-use OCP\Http\Client\IClient;
-use OCP\Http\Client\IClientService;
-use OCP\Http\Client\IResponse;
-use OCP\IConfig;
use OCP\IDBConnection;
use OCP\ILogger;
use OCP\IRequest;
use OCP\IUserManager;
use OCP\Share;
use OCP\Share\IShare;
-use PHPUnit\Framework\MockObject\Builder\InvocationMocker;
/**
* Class RequestHandlerTest
diff --git a/apps/files/lib/Capabilities.php b/apps/files/lib/Capabilities.php
index 7e6d5521fd7..ad5c4e1b773 100644
--- a/apps/files/lib/Capabilities.php
+++ b/apps/files/lib/Capabilities.php
@@ -26,14 +26,8 @@
namespace OCA\Files;
-use OC\DirectEditing\Manager;
use OCA\Files\Service\DirectEditingService;
use OCP\Capabilities\ICapability;
-use OCP\DirectEditing\ACreateEmpty;
-use OCP\DirectEditing\ACreateFromTemplate;
-use OCP\DirectEditing\IEditor;
-use OCP\DirectEditing\RegisterDirectEditorEvent;
-use OCP\EventDispatcher\IEventDispatcher;
use OCP\IConfig;
use OCP\IURLGenerator;
diff --git a/apps/files/lib/Controller/ApiController.php b/apps/files/lib/Controller/ApiController.php
index 9e6b6b550fc..3819e07909d 100644
--- a/apps/files/lib/Controller/ApiController.php
+++ b/apps/files/lib/Controller/ApiController.php
@@ -52,7 +52,6 @@ use OCP\IPreview;
use OCP\IRequest;
use OCP\IUserSession;
use OCP\Share\IManager;
-use Sabre\VObject\Property\Boolean;
/**
* Class ApiController
diff --git a/apps/files/lib/Controller/DirectEditingController.php b/apps/files/lib/Controller/DirectEditingController.php
index 099c65f73e6..ccef73b6a06 100644
--- a/apps/files/lib/Controller/DirectEditingController.php
+++ b/apps/files/lib/Controller/DirectEditingController.php
@@ -29,9 +29,6 @@ use OCA\Files\Service\DirectEditingService;
use OCP\AppFramework\Http;
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\OCSController;
-use OCP\DirectEditing\ACreateEmpty;
-use OCP\DirectEditing\ACreateFromTemplate;
-use OCP\DirectEditing\IEditor;
use OCP\DirectEditing\IManager;
use OCP\DirectEditing\RegisterDirectEditorEvent;
use OCP\EventDispatcher\IEventDispatcher;
diff --git a/apps/files/lib/Notification/Notifier.php b/apps/files/lib/Notification/Notifier.php
index 604408eee10..529eb7cbc77 100644
--- a/apps/files/lib/Notification/Notifier.php
+++ b/apps/files/lib/Notification/Notifier.php
@@ -30,8 +30,6 @@ namespace OCA\Files\Notification;
use OCA\Files\Db\TransferOwnershipMapper;
use OCP\AppFramework\Db\DoesNotExistException;
-use OCP\AppFramework\Http;
-use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\IURLGenerator;
use OCP\L10N\IFactory;
diff --git a/apps/files/tests/HelperTest.php b/apps/files/tests/HelperTest.php
index b756386a2bf..979894ec0c6 100644
--- a/apps/files/tests/HelperTest.php
+++ b/apps/files/tests/HelperTest.php
@@ -25,7 +25,6 @@
*
*/
-use OCA\Files\Tests;
/**
* Class Helper
diff --git a/apps/files_external/3rdparty/icewind/smb/src/Wrapped/Share.php b/apps/files_external/3rdparty/icewind/smb/src/Wrapped/Share.php
index 5a79c49fecf..a48de62e69d 100644
--- a/apps/files_external/3rdparty/icewind/smb/src/Wrapped/Share.php
+++ b/apps/files_external/3rdparty/icewind/smb/src/Wrapped/Share.php
@@ -13,14 +13,11 @@ use Icewind\SMB\Exception\DependencyException;
use Icewind\SMB\Exception\FileInUseException;
use Icewind\SMB\Exception\InvalidTypeException;
use Icewind\SMB\Exception\NotFoundException;
-use Icewind\SMB\Exception\InvalidRequestException;
use Icewind\SMB\IFileInfo;
use Icewind\SMB\INotifyHandler;
use Icewind\SMB\IServer;
use Icewind\SMB\ISystem;
use Icewind\Streams\CallbackWrapper;
-use Icewind\SMB\Native\NativeShare;
-use Icewind\SMB\Native\NativeServer;
class Share extends AbstractShare {
/**
diff --git a/apps/files_external/lib/AppInfo/Application.php b/apps/files_external/lib/AppInfo/Application.php
index 761eeff113f..47f52fbcb87 100644
--- a/apps/files_external/lib/AppInfo/Application.php
+++ b/apps/files_external/lib/AppInfo/Application.php
@@ -62,8 +62,6 @@ use OCA\Files_External\Lib\Config\IAuthMechanismProvider;
use OCA\Files_External\Lib\Config\IBackendProvider;
use OCA\Files_External\Service\BackendService;
use OCP\AppFramework\App;
-use OCP\AppFramework\IAppContainer;
-use OCP\Files\Config\IUserMountCache;
use OCP\IGroup;
use OCP\IUser;
use Symfony\Component\EventDispatcher\GenericEvent;
diff --git a/apps/files_external/lib/Lib/Backend/InvalidBackend.php b/apps/files_external/lib/Lib/Backend/InvalidBackend.php
index 5b574d8cd00..fc9b0992197 100644
--- a/apps/files_external/lib/Lib/Backend/InvalidBackend.php
+++ b/apps/files_external/lib/Lib/Backend/InvalidBackend.php
@@ -24,7 +24,6 @@
namespace OCA\Files_External\Lib\Backend;
-use OCA\Files_External\Lib\Storage\InvalidStorage;
use OCA\Files_External\Lib\StorageConfig;
use OCP\Files\StorageNotAvailableException;
use OCP\IUser;
diff --git a/apps/files_external/lib/Lib/Backend/Swift.php b/apps/files_external/lib/Lib/Backend/Swift.php
index e2d6c6848c4..86238b542b1 100644
--- a/apps/files_external/lib/Lib/Backend/Swift.php
+++ b/apps/files_external/lib/Lib/Backend/Swift.php
@@ -30,7 +30,6 @@ use OCA\Files_External\Lib\Auth\OpenStack\OpenStackV2;
use OCA\Files_External\Lib\Auth\OpenStack\Rackspace;
use OCA\Files_External\Lib\DefinitionParameter;
use OCA\Files_External\Lib\LegacyDependencyCheckPolyfill;
-use OCA\Files_External\Service\BackendService;
use OCP\IL10N;
class Swift extends Backend {
diff --git a/apps/files_external/lib/Migration/StorageMigrator.php b/apps/files_external/lib/Migration/StorageMigrator.php
index 8802e7b82b9..5fef0d3ac38 100644
--- a/apps/files_external/lib/Migration/StorageMigrator.php
+++ b/apps/files_external/lib/Migration/StorageMigrator.php
@@ -26,7 +26,6 @@ namespace OCA\Files_External\Migration;
use OCA\Files_External\Service\BackendService;
use OCA\Files_External\Service\DBConfigService;
-use OCA\Files_External\Service\GlobalLegacyStoragesService;
use OCA\Files_External\Service\LegacyStoragesService;
use OCA\Files_External\Service\StoragesService;
use OCA\Files_External\Service\UserLegacyStoragesService;
diff --git a/apps/files_external/tests/Controller/GlobalStoragesControllerTest.php b/apps/files_external/tests/Controller/GlobalStoragesControllerTest.php
index f784a726694..b829525b516 100644
--- a/apps/files_external/tests/Controller/GlobalStoragesControllerTest.php
+++ b/apps/files_external/tests/Controller/GlobalStoragesControllerTest.php
@@ -28,7 +28,6 @@ namespace OCA\Files_External\Tests\Controller;
use OCA\Files_External\Controller\GlobalStoragesController;
use OCA\Files_External\Service\BackendService;
-use OCP\AppFramework\Http;
use OCP\IL10N;
use OCP\ILogger;
use OCP\IRequest;
diff --git a/apps/files_sharing/lib/Controller/PublicPreviewController.php b/apps/files_sharing/lib/Controller/PublicPreviewController.php
index 076b3a381f8..d0c2296f0db 100644
--- a/apps/files_sharing/lib/Controller/PublicPreviewController.php
+++ b/apps/files_sharing/lib/Controller/PublicPreviewController.php
@@ -25,7 +25,6 @@
namespace OCA\Files_Sharing\Controller;
-use OCP\AppFramework\Controller;
use OCP\AppFramework\Http;
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\Http\FileDisplayResponse;
diff --git a/apps/files_sharing/lib/Controller/ShareesAPIController.php b/apps/files_sharing/lib/Controller/ShareesAPIController.php
index 14ed9041149..63c96151ebc 100644
--- a/apps/files_sharing/lib/Controller/ShareesAPIController.php
+++ b/apps/files_sharing/lib/Controller/ShareesAPIController.php
@@ -34,7 +34,6 @@ declare(strict_types=1);
namespace OCA\Files_Sharing\Controller;
-use function array_filter;
use function array_slice;
use function array_values;
use Generator;
diff --git a/apps/files_sharing/lib/Helper.php b/apps/files_sharing/lib/Helper.php
index b487aab6d7f..3efb4e25eef 100644
--- a/apps/files_sharing/lib/Helper.php
+++ b/apps/files_sharing/lib/Helper.php
@@ -29,9 +29,6 @@ namespace OCA\Files_Sharing;
use OC\Files\Filesystem;
use OC\Files\View;
-use OCP\Files\NotFoundException;
-use OCP\Share\Exceptions\ShareNotFound;
-use OCP\User;
class Helper {
diff --git a/apps/files_sharing/lib/Hooks.php b/apps/files_sharing/lib/Hooks.php
index 831e37e7e06..cb9e20bb869 100644
--- a/apps/files_sharing/lib/Hooks.php
+++ b/apps/files_sharing/lib/Hooks.php
@@ -29,7 +29,6 @@
namespace OCA\Files_Sharing;
use OC\Files\Filesystem;
-use OCA\FederatedFileSharing\DiscoveryManager;
class Hooks {
diff --git a/apps/files_sharing/lib/Middleware/SharingCheckMiddleware.php b/apps/files_sharing/lib/Middleware/SharingCheckMiddleware.php
index de168c43f52..4f0b547e433 100644
--- a/apps/files_sharing/lib/Middleware/SharingCheckMiddleware.php
+++ b/apps/files_sharing/lib/Middleware/SharingCheckMiddleware.php
@@ -27,7 +27,6 @@
namespace OCA\Files_Sharing\Middleware;
use OCA\Files_Sharing\Controller\ExternalSharesController;
-use OCA\Files_Sharing\Controller\ShareController;
use OCA\Files_Sharing\Exceptions\S2SException;
use OCP\App\IAppManager;
use OCP\AppFramework\Controller;
diff --git a/apps/files_sharing/tests/TestCase.php b/apps/files_sharing/tests/TestCase.php
index 8ea72943be4..c9f024cd67a 100644
--- a/apps/files_sharing/tests/TestCase.php
+++ b/apps/files_sharing/tests/TestCase.php
@@ -32,7 +32,6 @@
namespace OCA\Files_Sharing\Tests;
-use OC\Files\Cache\Scanner;
use OC\Files\Filesystem;
use OCA\Files_Sharing\AppInfo\Application;
use OCP\Share\IShare;
diff --git a/apps/files_trashbin/lib/AppInfo/Application.php b/apps/files_trashbin/lib/AppInfo/Application.php
index e6954a7e0ba..59f1b1d8c56 100644
--- a/apps/files_trashbin/lib/AppInfo/Application.php
+++ b/apps/files_trashbin/lib/AppInfo/Application.php
@@ -34,7 +34,6 @@ use OCA\Files_Trashbin\Trash\ITrashManager;
use OCA\Files_Trashbin\Trash\TrashManager;
use OCP\AppFramework\App;
use OCP\AppFramework\IAppContainer;
-use OCP\AppFramework\Utility\ITimeFactory;
class Application extends App {
public function __construct (array $urlParams = []) {
diff --git a/apps/files_trashbin/lib/Sabre/AbstractTrash.php b/apps/files_trashbin/lib/Sabre/AbstractTrash.php
index a32b42429a5..b1088f13221 100644
--- a/apps/files_trashbin/lib/Sabre/AbstractTrash.php
+++ b/apps/files_trashbin/lib/Sabre/AbstractTrash.php
@@ -29,7 +29,6 @@ namespace OCA\Files_Trashbin\Sabre;
use OCA\Files_Trashbin\Trash\ITrashItem;
use OCA\Files_Trashbin\Trash\ITrashManager;
use OCP\Files\FileInfo;
-use OCP\IUser;
abstract class AbstractTrash implements ITrash {
/** @var ITrashItem */
diff --git a/apps/files_trashbin/lib/Sabre/PropfindPlugin.php b/apps/files_trashbin/lib/Sabre/PropfindPlugin.php
index e27400372d3..53619c6e85c 100644
--- a/apps/files_trashbin/lib/Sabre/PropfindPlugin.php
+++ b/apps/files_trashbin/lib/Sabre/PropfindPlugin.php
@@ -28,7 +28,6 @@ declare(strict_types=1);
namespace OCA\Files_Trashbin\Sabre;
use OCA\DAV\Connector\Sabre\FilesPlugin;
-use OCP\Constants;
use OCP\IPreview;
use Sabre\DAV\INode;
use Sabre\DAV\PropFind;
diff --git a/apps/files_trashbin/lib/Storage.php b/apps/files_trashbin/lib/Storage.php
index c9f1a928f3b..9cf154e9bfd 100644
--- a/apps/files_trashbin/lib/Storage.php
+++ b/apps/files_trashbin/lib/Storage.php
@@ -31,7 +31,6 @@ namespace OCA\Files_Trashbin;
use OC\Files\Filesystem;
use OC\Files\Storage\Wrapper\Wrapper;
-use OC\Files\View;
use OCA\Files_Trashbin\Events\MoveToTrashEvent;
use OCA\Files_Trashbin\Trash\ITrashManager;
use OCP\Encryption\Exceptions\GenericEncryptionException;
diff --git a/apps/files_trashbin/lib/Trash/ITrashBackend.php b/apps/files_trashbin/lib/Trash/ITrashBackend.php
index 478dfa3971c..e0d7ea50ac8 100644
--- a/apps/files_trashbin/lib/Trash/ITrashBackend.php
+++ b/apps/files_trashbin/lib/Trash/ITrashBackend.php
@@ -23,9 +23,7 @@
namespace OCA\Files_Trashbin\Trash;
-use OCP\Files\FileInfo;
use OCP\Files\Node;
-use OCP\Files\SimpleFS\ISimpleFile;
use OCP\Files\Storage\IStorage;
use OCP\IUser;
diff --git a/apps/files_trashbin/lib/Trash/TrashManager.php b/apps/files_trashbin/lib/Trash/TrashManager.php
index d5f8eb1330f..8d75ac21658 100644
--- a/apps/files_trashbin/lib/Trash/TrashManager.php
+++ b/apps/files_trashbin/lib/Trash/TrashManager.php
@@ -23,8 +23,6 @@
namespace OCA\Files_Trashbin\Trash;
-use OCP\Files\FileInfo;
-use OCP\Files\Mount\IMountPoint;
use OCP\Files\Storage\IStorage;
use OCP\IUser;
diff --git a/apps/files_trashbin/tests/TrashbinTest.php b/apps/files_trashbin/tests/TrashbinTest.php
index e682d0dd51f..2e206538384 100644
--- a/apps/files_trashbin/tests/TrashbinTest.php
+++ b/apps/files_trashbin/tests/TrashbinTest.php
@@ -28,7 +28,6 @@
*
*/
-use OCA\Files_Trashbin\Tests;
use OCA\Files_Sharing\AppInfo\Application;
/**
diff --git a/apps/files_versions/lib/BackgroundJob/ExpireVersions.php b/apps/files_versions/lib/BackgroundJob/ExpireVersions.php
index c45e7c4a244..cb2e0abb0c4 100644
--- a/apps/files_versions/lib/BackgroundJob/ExpireVersions.php
+++ b/apps/files_versions/lib/BackgroundJob/ExpireVersions.php
@@ -25,7 +25,6 @@
namespace OCA\Files_Versions\BackgroundJob;
-use OCA\Files_Versions\AppInfo\Application;
use OCA\Files_Versions\Expiration;
use OCA\Files_Versions\Storage;
use OCP\IUser;
diff --git a/apps/files_versions/lib/Sabre/RestoreFolder.php b/apps/files_versions/lib/Sabre/RestoreFolder.php
index eef12dcfd18..89f379e3c1c 100644
--- a/apps/files_versions/lib/Sabre/RestoreFolder.php
+++ b/apps/files_versions/lib/Sabre/RestoreFolder.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OCA\Files_Versions\Sabre;
-use OCP\IUser;
use Sabre\DAV\Exception\Forbidden;
use Sabre\DAV\ICollection;
use Sabre\DAV\IMoveTarget;
diff --git a/apps/files_versions/lib/Sabre/VersionCollection.php b/apps/files_versions/lib/Sabre/VersionCollection.php
index eeb5453e9a0..e2ad562e8bc 100644
--- a/apps/files_versions/lib/Sabre/VersionCollection.php
+++ b/apps/files_versions/lib/Sabre/VersionCollection.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OCA\Files_Versions\Sabre;
-use OCA\Files_Versions\Storage;
use OCA\Files_Versions\Versions\IVersion;
use OCA\Files_Versions\Versions\IVersionManager;
use OCP\Files\File;
diff --git a/apps/files_versions/lib/Versions/IVersionBackend.php b/apps/files_versions/lib/Versions/IVersionBackend.php
index d526df69967..dd7e5f96398 100644
--- a/apps/files_versions/lib/Versions/IVersionBackend.php
+++ b/apps/files_versions/lib/Versions/IVersionBackend.php
@@ -29,7 +29,6 @@ namespace OCA\Files_Versions\Versions;
use OCP\Files\File;
use OCP\Files\FileInfo;
use OCP\Files\NotFoundException;
-use OCP\Files\SimpleFS\ISimpleFile;
use OCP\Files\Storage\IStorage;
use OCP\IUser;
diff --git a/apps/files_versions/tests/Controller/PreviewControllerTest.php b/apps/files_versions/tests/Controller/PreviewControllerTest.php
index e5461d23070..084bb25da82 100644
--- a/apps/files_versions/tests/Controller/PreviewControllerTest.php
+++ b/apps/files_versions/tests/Controller/PreviewControllerTest.php
@@ -24,7 +24,6 @@
namespace OCA\Files_Versions\Tests\Controller;
-use OC\User\User;
use OCA\Files_Versions\Controller\PreviewController;
use OCA\Files_Versions\Versions\IVersionManager;
use OCP\AppFramework\Http;
diff --git a/apps/files_versions/tests/VersioningTest.php b/apps/files_versions/tests/VersioningTest.php
index e07a1816c30..7517ec88e48 100644
--- a/apps/files_versions/tests/VersioningTest.php
+++ b/apps/files_versions/tests/VersioningTest.php
@@ -38,7 +38,6 @@ require_once __DIR__ . '/../appinfo/app.php';
use OC\Files\Storage\Temporary;
use OCP\IConfig;
use OCP\IUser;
-use OCP\Share\IShare;
/**
* Class Test_Files_versions
diff --git a/apps/settings/lib/AppInfo/Application.php b/apps/settings/lib/AppInfo/Application.php
index 4d837500c4c..96c87341290 100644
--- a/apps/settings/lib/AppInfo/Application.php
+++ b/apps/settings/lib/AppInfo/Application.php
@@ -37,13 +37,7 @@ use OC\AppFramework\Utility\TimeFactory;
use OC\Authentication\Token\IProvider;
use OC\Authentication\Token\IToken;
use OC\Server;
-use OCA\Settings\Activity\GroupProvider;
-use OCA\Settings\Activity\GroupSetting;
use OCA\Settings\Activity\Provider;
-use OCA\Settings\Activity\SecurityFilter;
-use OCA\Settings\Activity\SecurityProvider;
-use OCA\Settings\Activity\SecuritySetting;
-use OCA\Settings\Activity\Setting;
use OCA\Settings\Hooks;
use OCA\Settings\Mailer\NewUserMailHelper;
use OCA\Settings\Middleware\SubadminMiddleware;
diff --git a/apps/settings/lib/Controller/AuthSettingsController.php b/apps/settings/lib/Controller/AuthSettingsController.php
index 7f6d74e5fc7..405044746a3 100644
--- a/apps/settings/lib/Controller/AuthSettingsController.php
+++ b/apps/settings/lib/Controller/AuthSettingsController.php
@@ -40,7 +40,6 @@ use OC\Authentication\Exceptions\WipeTokenException;
use OC\Authentication\Token\INamedToken;
use OC\Authentication\Token\IProvider;
use OC\Authentication\Token\IToken;
-use OC\Authentication\Token\IWipeableToken;
use OC\Authentication\Token\RemoteWipe;
use OCA\Settings\Activity\Provider;
use OCP\Activity\IManager;
diff --git a/apps/settings/lib/Controller/UsersController.php b/apps/settings/lib/Controller/UsersController.php
index cfbe35eb201..cb9435e4939 100644
--- a/apps/settings/lib/Controller/UsersController.php
+++ b/apps/settings/lib/Controller/UsersController.php
@@ -35,7 +35,6 @@ use OC\AppFramework\Http;
use OC\Encryption\Exceptions\ModuleDoesNotExistsException;
use OC\ForbiddenException;
use OC\Security\IdentityProof\Manager;
-use OCA\Settings\AppInfo\Application;
use OCA\Settings\BackgroundJobs\VerifyUserData;
use OCA\User_LDAP\User_Proxy;
use OCP\App\IAppManager;
diff --git a/apps/settings/lib/Mailer/NewUserMailHelper.php b/apps/settings/lib/Mailer/NewUserMailHelper.php
index 7352ac0ec6f..ca6a5947527 100644
--- a/apps/settings/lib/Mailer/NewUserMailHelper.php
+++ b/apps/settings/lib/Mailer/NewUserMailHelper.php
@@ -33,7 +33,6 @@ namespace OCA\Settings\Mailer;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\Defaults;
use OCP\IConfig;
-use OCP\IL10N;
use OCP\IURLGenerator;
use OCP\IUser;
use OCP\L10N\IFactory;
diff --git a/apps/settings/lib/Settings/Admin/Sharing.php b/apps/settings/lib/Settings/Admin/Sharing.php
index 980e579d360..080f866ae56 100644
--- a/apps/settings/lib/Settings/Admin/Sharing.php
+++ b/apps/settings/lib/Settings/Admin/Sharing.php
@@ -34,7 +34,6 @@ use OCP\AppFramework\Http\TemplateResponse;
use OCP\Constants;
use OCP\IConfig;
use OCP\IL10N;
-use OCP\L10N\IFactory;
use OCP\Settings\ISettings;
use OCP\Share\IManager;
use OCP\Util;
diff --git a/apps/settings/tests/Mailer/NewUserMailHelperTest.php b/apps/settings/tests/Mailer/NewUserMailHelperTest.php
index a6371c37a92..7e2fc514168 100644
--- a/apps/settings/tests/Mailer/NewUserMailHelperTest.php
+++ b/apps/settings/tests/Mailer/NewUserMailHelperTest.php
@@ -32,7 +32,6 @@ namespace OCA\Settings\Tests\Mailer;
use OC\Mail\EMailTemplate;
use OC\Mail\Message;
-use OCA\Settings\Mailer\NewUserMailHelper;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\Defaults;
use OCP\IConfig;
diff --git a/apps/theming/lib/Controller/ThemingController.php b/apps/theming/lib/Controller/ThemingController.php
index d043c64f853..6a17b23722e 100644
--- a/apps/theming/lib/Controller/ThemingController.php
+++ b/apps/theming/lib/Controller/ThemingController.php
@@ -48,8 +48,6 @@ use OCP\AppFramework\Http\DataDownloadResponse;
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\Http\FileDisplayResponse;
use OCP\AppFramework\Http\NotFoundResponse;
-use OCP\AppFramework\Utility\ITimeFactory;
-use OCP\Files\File;
use OCP\Files\IAppData;
use OCP\Files\NotFoundException;
use OCP\Files\NotPermittedException;
diff --git a/apps/theming/tests/Controller/IconControllerTest.php b/apps/theming/tests/Controller/IconControllerTest.php
index 7f41e8cc6d9..c159c7237ea 100644
--- a/apps/theming/tests/Controller/IconControllerTest.php
+++ b/apps/theming/tests/Controller/IconControllerTest.php
@@ -34,7 +34,6 @@ use OCA\Theming\Controller\IconController;
use OCA\Theming\IconBuilder;
use OCA\Theming\ImageManager;
use OCA\Theming\ThemingDefaults;
-use OCA\Theming\Util;
use OCP\AppFramework\Http;
use OCP\AppFramework\Http\DataDisplayResponse;
use OCP\AppFramework\Http\FileDisplayResponse;
diff --git a/apps/theming/tests/Controller/ThemingControllerTest.php b/apps/theming/tests/Controller/ThemingControllerTest.php
index 8c5f111acee..608a03e7bd5 100644
--- a/apps/theming/tests/Controller/ThemingControllerTest.php
+++ b/apps/theming/tests/Controller/ThemingControllerTest.php
@@ -35,7 +35,6 @@
namespace OCA\Theming\Tests\Controller;
-use OC\Files\AppData\Factory;
use OC\L10N\L10N;
use OC\Template\SCSSCacher;
use OCA\Theming\Controller\ThemingController;
@@ -47,13 +46,11 @@ use OCP\AppFramework\Http;
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\Files\IAppData;
-use OCP\Files\IRootFolder;
use OCP\Files\NotFoundException;
use OCP\Files\SimpleFS\ISimpleFile;
use OCP\Files\SimpleFS\ISimpleFolder;
use OCP\IConfig;
use OCP\IL10N;
-use OCP\ILogger;
use OCP\IRequest;
use OCP\ITempManager;
use OCP\IURLGenerator;
diff --git a/apps/theming/tests/ImageManagerTest.php b/apps/theming/tests/ImageManagerTest.php
index 2360006958e..fbdadf697e1 100644
--- a/apps/theming/tests/ImageManagerTest.php
+++ b/apps/theming/tests/ImageManagerTest.php
@@ -27,7 +27,6 @@
namespace OCA\Theming\Tests;
use OCA\Theming\ImageManager;
-use OCA\Theming\ThemingDefaults;
use OCP\Files\IAppData;
use OCP\Files\NotFoundException;
use OCP\Files\SimpleFS\ISimpleFile;
diff --git a/apps/theming/tests/ThemingDefaultsTest.php b/apps/theming/tests/ThemingDefaultsTest.php
index 458b602d62b..a06cdb8f7a8 100644
--- a/apps/theming/tests/ThemingDefaultsTest.php
+++ b/apps/theming/tests/ThemingDefaultsTest.php
@@ -41,7 +41,6 @@ use OCP\App\IAppManager;
use OCP\Files\IAppData;
use OCP\Files\NotFoundException;
use OCP\Files\SimpleFS\ISimpleFile;
-use OCP\Files\SimpleFS\ISimpleFolder;
use OCP\ICache;
use OCP\ICacheFactory;
use OCP\IConfig;
diff --git a/apps/theming/tests/UtilTest.php b/apps/theming/tests/UtilTest.php
index f0f7089b624..969d35f7d27 100644
--- a/apps/theming/tests/UtilTest.php
+++ b/apps/theming/tests/UtilTest.php
@@ -30,7 +30,6 @@ namespace OCA\Theming\Tests;
use OCA\Theming\Util;
use OCP\App\IAppManager;
use OCP\Files\IAppData;
-use OCP\Files\IRootFolder;
use OCP\Files\NotFoundException;
use OCP\Files\SimpleFS\ISimpleFile;
use OCP\Files\SimpleFS\ISimpleFolder;
diff --git a/apps/twofactor_backupcodes/lib/AppInfo/Application.php b/apps/twofactor_backupcodes/lib/AppInfo/Application.php
index d71e7654cb5..4c5d852f956 100644
--- a/apps/twofactor_backupcodes/lib/AppInfo/Application.php
+++ b/apps/twofactor_backupcodes/lib/AppInfo/Application.php
@@ -36,7 +36,6 @@ use OCA\TwoFactorBackupCodes\Notifications\Notifier;
use OCP\AppFramework\App;
use OCP\Authentication\TwoFactorAuth\IRegistry;
use OCP\EventDispatcher\IEventDispatcher;
-use OCP\IL10N;
use OCP\Notification\IManager;
use OCP\Util;
diff --git a/apps/twofactor_backupcodes/lib/Db/BackupCodeMapper.php b/apps/twofactor_backupcodes/lib/Db/BackupCodeMapper.php
index 8316e9d9223..73883b3eb30 100644
--- a/apps/twofactor_backupcodes/lib/Db/BackupCodeMapper.php
+++ b/apps/twofactor_backupcodes/lib/Db/BackupCodeMapper.php
@@ -25,7 +25,6 @@
namespace OCA\TwoFactorBackupCodes\Db;
-use OCP\AppFramework\Db\Mapper;
use OCP\AppFramework\Db\QBMapper;
use OCP\DB\QueryBuilder\IQueryBuilder;
use OCP\IDBConnection;
diff --git a/apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php b/apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php
index c77c6b01d8c..ffb456792a4 100644
--- a/apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php
+++ b/apps/twofactor_backupcodes/lib/Service/BackupCodeStorage.php
@@ -25,17 +25,13 @@
namespace OCA\TwoFactorBackupCodes\Service;
-use BadMethodCallException;
use OCA\TwoFactorBackupCodes\Db\BackupCode;
use OCA\TwoFactorBackupCodes\Db\BackupCodeMapper;
use OCA\TwoFactorBackupCodes\Event\CodesGenerated;
-use OCP\Activity\IManager;
use OCP\EventDispatcher\IEventDispatcher;
-use OCP\ILogger;
use OCP\IUser;
use OCP\Security\IHasher;
use OCP\Security\ISecureRandom;
-use Symfony\Component\EventDispatcher\EventDispatcherInterface;
class BackupCodeStorage {
diff --git a/apps/updatenotification/lib/Settings/Admin.php b/apps/updatenotification/lib/Settings/Admin.php
index 8d36e774b06..db2efffc46b 100644
--- a/apps/updatenotification/lib/Settings/Admin.php
+++ b/apps/updatenotification/lib/Settings/Admin.php
@@ -33,7 +33,6 @@ use OCP\AppFramework\Http\TemplateResponse;
use OCP\IConfig;
use OCP\IDateTimeFormatter;
use OCP\IGroupManager;
-use OCP\IUserSession;
use OCP\L10N\IFactory;
use OCP\Settings\ISettings;
use OCP\Support\Subscription\IRegistry;
diff --git a/apps/updatenotification/tests/Settings/AdminTest.php b/apps/updatenotification/tests/Settings/AdminTest.php
index af5db66795a..7ac404be57f 100644
--- a/apps/updatenotification/tests/Settings/AdminTest.php
+++ b/apps/updatenotification/tests/Settings/AdminTest.php
@@ -36,7 +36,6 @@ use OCP\IConfig;
use OCP\IDateTimeFormatter;
use OCP\IGroup;
use OCP\IGroupManager;
-use OCP\IUserSession;
use OCP\L10N\IFactory;
use OCP\L10N\ILanguageIterator;
use OCP\Support\Subscription\IRegistry;
diff --git a/apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserCleanUp.php b/apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserCleanUp.php
index 4bb5bd71647..b656b50ef50 100644
--- a/apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserCleanUp.php
+++ b/apps/user_ldap/tests/Integration/Lib/User/IntegrationTestUserCleanUp.php
@@ -23,7 +23,6 @@
namespace OCA\User_LDAP\Tests\Integration\Lib\User;
-use OC\User\NoUserException;
use OCA\User_LDAP\Jobs\CleanUp;
use OCA\User_LDAP\Mapping\UserMapping;
use OCA\User_LDAP\Tests\Integration\AbstractIntegrationTest;
diff --git a/apps/user_ldap/tests/Jobs/SyncTest.php b/apps/user_ldap/tests/Jobs/SyncTest.php
index dc21255da39..8cab95fc801 100644
--- a/apps/user_ldap/tests/Jobs/SyncTest.php
+++ b/apps/user_ldap/tests/Jobs/SyncTest.php
@@ -38,7 +38,6 @@ use OCP\IConfig;
use OCP\IDBConnection;
use OCP\IUserManager;
use OCP\Notification\IManager;
-use function Sodium\memcmp;
use Test\TestCase;
class SyncTest extends TestCase {
diff --git a/apps/user_ldap/tests/Settings/AdminTest.php b/apps/user_ldap/tests/Settings/AdminTest.php
index 54008e3def7..8f3a699af5d 100644
--- a/apps/user_ldap/tests/Settings/AdminTest.php
+++ b/apps/user_ldap/tests/Settings/AdminTest.php
@@ -27,7 +27,6 @@
namespace OCA\User_LDAP\Tests\Settings;
use OCA\User_LDAP\Configuration;
-use OCA\User_LDAP\Helper;
use OCA\User_LDAP\Settings\Admin;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\IL10N;
diff --git a/apps/user_ldap/tests/User_ProxyTest.php b/apps/user_ldap/tests/User_ProxyTest.php
index f2e49d4dbec..0a073b3948e 100644
--- a/apps/user_ldap/tests/User_ProxyTest.php
+++ b/apps/user_ldap/tests/User_ProxyTest.php
@@ -27,7 +27,6 @@
namespace OCA\User_LDAP\Tests;
-use OCA\User_LDAP\ILDAPUserPlugin;
use OCA\User_LDAP\ILDAPWrapper;
use OCA\User_LDAP\User_Proxy;
use OCA\User_LDAP\UserPluginManager;
diff --git a/apps/workflowengine/lib/Check/FileSize.php b/apps/workflowengine/lib/Check/FileSize.php
index 736a3d932fb..ce1bd4718f9 100644
--- a/apps/workflowengine/lib/Check/FileSize.php
+++ b/apps/workflowengine/lib/Check/FileSize.php
@@ -27,7 +27,6 @@ use OCP\IL10N;
use OCP\IRequest;
use OCP\Util;
use OCP\WorkflowEngine\ICheck;
-use OCP\WorkflowEngine\IEntity;
class FileSize implements ICheck {
diff --git a/build/integration/features/bootstrap/CapabilitiesContext.php b/build/integration/features/bootstrap/CapabilitiesContext.php
index 1de5001d136..f38ba17551a 100644
--- a/build/integration/features/bootstrap/CapabilitiesContext.php
+++ b/build/integration/features/bootstrap/CapabilitiesContext.php
@@ -26,10 +26,6 @@
*/
use Behat\Behat\Context\Context;
use Behat\Behat\Context\SnippetAcceptingContext;
-use Behat\Behat\Hook\Scope\AfterScenarioScope;
-use Behat\Behat\Hook\Scope\BeforeScenarioScope;
-use GuzzleHttp\Client;
-use GuzzleHttp\Message\ResponseInterface;
use PHPUnit\Framework\Assert;
require __DIR__ . '/../../vendor/autoload.php';
diff --git a/build/integration/features/bootstrap/Download.php b/build/integration/features/bootstrap/Download.php
index e3b47b3ef33..71a96eb585f 100644
--- a/build/integration/features/bootstrap/Download.php
+++ b/build/integration/features/bootstrap/Download.php
@@ -22,8 +22,6 @@
*
*/
-use GuzzleHttp\Client;
-use GuzzleHttp\Message\ResponseInterface;
use PHPUnit\Framework\Assert;
require __DIR__ . '/../../vendor/autoload.php';
diff --git a/build/integration/features/bootstrap/FederationContext.php b/build/integration/features/bootstrap/FederationContext.php
index 092f0326d3a..d710b9e502d 100644
--- a/build/integration/features/bootstrap/FederationContext.php
+++ b/build/integration/features/bootstrap/FederationContext.php
@@ -26,8 +26,6 @@
*/
use Behat\Behat\Context\Context;
use Behat\Behat\Context\SnippetAcceptingContext;
-use GuzzleHttp\Client;
-use GuzzleHttp\Message\ResponseInterface;
require __DIR__ . '/../../vendor/autoload.php';
diff --git a/build/integration/features/bootstrap/FilesDropContext.php b/build/integration/features/bootstrap/FilesDropContext.php
index bc54f51cc81..8f522d6f2ce 100644
--- a/build/integration/features/bootstrap/FilesDropContext.php
+++ b/build/integration/features/bootstrap/FilesDropContext.php
@@ -24,7 +24,6 @@
*/
use Behat\Behat\Context\Context;
use Behat\Behat\Context\SnippetAcceptingContext;
-use Behat\Behat\Tester\Exception\PendingException;
use GuzzleHttp\Client;
require __DIR__ . '/../../vendor/autoload.php';
diff --git a/build/integration/features/bootstrap/ShareesContext.php b/build/integration/features/bootstrap/ShareesContext.php
index 4042bb64f5c..cf472e0321e 100644
--- a/build/integration/features/bootstrap/ShareesContext.php
+++ b/build/integration/features/bootstrap/ShareesContext.php
@@ -26,8 +26,6 @@
*/
use Behat\Behat\Context\Context;
use Behat\Behat\Context\SnippetAcceptingContext;
-use PHPUnit\Framework\Assert;
-use Psr\Http\Message\ResponseInterface;
require __DIR__ . '/../../vendor/autoload.php';
diff --git a/build/integration/features/bootstrap/SharingContext.php b/build/integration/features/bootstrap/SharingContext.php
index cace64e4f8a..ec03283de5a 100644
--- a/build/integration/features/bootstrap/SharingContext.php
+++ b/build/integration/features/bootstrap/SharingContext.php
@@ -22,8 +22,6 @@
*/
use Behat\Behat\Context\Context;
use Behat\Behat\Context\SnippetAcceptingContext;
-use PHPUnit\Framework\Assert;
-use Psr\Http\Message\ResponseInterface;
require __DIR__ . '/../../vendor/autoload.php';
diff --git a/core/Application.php b/core/Application.php
index 879ac1cff74..c2da7f8d194 100644
--- a/core/Application.php
+++ b/core/Application.php
@@ -44,7 +44,6 @@ use OC\DB\SchemaWrapper;
use OCP\AppFramework\App;
use OCP\EventDispatcher\IEventDispatcher;
use OCP\IDBConnection;
-use OCP\IServerContainer;
use OCP\User\Events\UserDeletedEvent;
use OCP\Util;
use Symfony\Component\EventDispatcher\GenericEvent;
diff --git a/core/Command/App/CheckCode.php b/core/Command/App/CheckCode.php
index b658ccbe2ea..3a17114261f 100644
--- a/core/Command/App/CheckCode.php
+++ b/core/Command/App/CheckCode.php
@@ -34,7 +34,6 @@ use OC\App\CodeChecker\InfoChecker;
use OC\App\CodeChecker\LanguageParseChecker;
use OC\App\CodeChecker\PrivateCheck;
use OC\App\CodeChecker\StrongComparisonCheck;
-use OC\App\InfoParser;
use Stecman\Component\Symfony\Console\BashCompletion\Completion\CompletionAwareInterface;
use Stecman\Component\Symfony\Console\BashCompletion\CompletionContext;
use Symfony\Component\Console\Command\Command;
diff --git a/core/Command/TwoFactorAuth/Disable.php b/core/Command/TwoFactorAuth/Disable.php
index d08bf7b767e..1dd3a2cf64d 100644
--- a/core/Command/TwoFactorAuth/Disable.php
+++ b/core/Command/TwoFactorAuth/Disable.php
@@ -23,7 +23,6 @@
namespace OC\Core\Command\TwoFactorAuth;
-use OC\Authentication\TwoFactorAuth\Manager;
use OC\Authentication\TwoFactorAuth\ProviderManager;
use OCP\IUserManager;
use Symfony\Component\Console\Input\InputArgument;
diff --git a/core/Controller/CssController.php b/core/Controller/CssController.php
index b332ee1aa26..3e7215966bc 100644
--- a/core/Controller/CssController.php
+++ b/core/Controller/CssController.php
@@ -41,7 +41,6 @@ use OCP\Files\IAppData;
use OCP\Files\NotFoundException;
use OCP\Files\SimpleFS\ISimpleFile;
use OCP\Files\SimpleFS\ISimpleFolder;
-use OCP\IConfig;
use OCP\IRequest;
class CssController extends Controller {
diff --git a/core/Controller/RecommendedAppsController.php b/core/Controller/RecommendedAppsController.php
index f0860f46a3f..fe3435d9be8 100644
--- a/core/Controller/RecommendedAppsController.php
+++ b/core/Controller/RecommendedAppsController.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OC\Core\Controller;
use OCP\AppFramework\Controller;
-use OCP\AppFramework\Http\ContentSecurityPolicy;
use OCP\AppFramework\Http\Response;
use OCP\AppFramework\Http\StandaloneTemplateResponse;
use OCP\IInitialStateService;
diff --git a/core/Controller/SetupController.php b/core/Controller/SetupController.php
index 302edccf7a6..fc589392aca 100644
--- a/core/Controller/SetupController.php
+++ b/core/Controller/SetupController.php
@@ -34,7 +34,6 @@ namespace OC\Core\Controller;
use OC\Setup;
use OCP\ILogger;
-use function urlencode;
class SetupController {
/** @var Setup */
diff --git a/core/Migrations/Version15000Date20181015062942.php b/core/Migrations/Version15000Date20181015062942.php
index 22c430f7a96..eaeaf0dd268 100644
--- a/core/Migrations/Version15000Date20181015062942.php
+++ b/core/Migrations/Version15000Date20181015062942.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OC\Core\Migrations;
use Closure;
-use Doctrine\DBAL\Types\Type;
use OCP\DB\ISchemaWrapper;
use OCP\Migration\IOutput;
use OCP\Migration\SimpleMigrationStep;
diff --git a/core/Migrations/Version18000Date20191204114856.php b/core/Migrations/Version18000Date20191204114856.php
index 995af4de2f1..256b42f9597 100644
--- a/core/Migrations/Version18000Date20191204114856.php
+++ b/core/Migrations/Version18000Date20191204114856.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OC\Core\Migrations;
use Closure;
-use Doctrine\DBAL\Types\Type;
use OCP\DB\ISchemaWrapper;
use OCP\IDBConnection;
use OCP\Migration\SimpleMigrationStep;
diff --git a/lib/private/App/AppStore/Fetcher/AppFetcher.php b/lib/private/App/AppStore/Fetcher/AppFetcher.php
index d6affe4f09b..c0917b17469 100644
--- a/lib/private/App/AppStore/Fetcher/AppFetcher.php
+++ b/lib/private/App/AppStore/Fetcher/AppFetcher.php
@@ -35,7 +35,6 @@ use OCP\AppFramework\Utility\ITimeFactory;
use OCP\Http\Client\IClientService;
use OCP\IConfig;
use OCP\ILogger;
-use OCP\Util;
class AppFetcher extends Fetcher {
diff --git a/lib/private/App/AppStore/Fetcher/Fetcher.php b/lib/private/App/AppStore/Fetcher/Fetcher.php
index e2876dd28c6..fd0600a3ce4 100644
--- a/lib/private/App/AppStore/Fetcher/Fetcher.php
+++ b/lib/private/App/AppStore/Fetcher/Fetcher.php
@@ -38,7 +38,6 @@ use OCP\Files\NotFoundException;
use OCP\Http\Client\IClientService;
use OCP\IConfig;
use OCP\ILogger;
-use OCP\Util;
abstract class Fetcher {
const INVALIDATE_AFTER_SECONDS = 300;
diff --git a/lib/private/App/CodeChecker/InfoChecker.php b/lib/private/App/CodeChecker/InfoChecker.php
index 0db9571d48a..038fd34f436 100644
--- a/lib/private/App/CodeChecker/InfoChecker.php
+++ b/lib/private/App/CodeChecker/InfoChecker.php
@@ -24,8 +24,6 @@
namespace OC\App\CodeChecker;
use OC\Hooks\BasicEmitter;
-use OCP\App\AppPathNotFoundException;
-use OCP\App\IAppManager;
class InfoChecker extends BasicEmitter {
diff --git a/lib/private/App/DependencyAnalyzer.php b/lib/private/App/DependencyAnalyzer.php
index a59e8c21735..1ebf4c8e292 100644
--- a/lib/private/App/DependencyAnalyzer.php
+++ b/lib/private/App/DependencyAnalyzer.php
@@ -29,7 +29,6 @@
namespace OC\App;
-use OCP\IConfig;
use OCP\IL10N;
class DependencyAnalyzer {
diff --git a/lib/private/AppFramework/Middleware/PublicShare/PublicShareMiddleware.php b/lib/private/AppFramework/Middleware/PublicShare/PublicShareMiddleware.php
index 131612848cb..b6e2611179f 100644
--- a/lib/private/AppFramework/Middleware/PublicShare/PublicShareMiddleware.php
+++ b/lib/private/AppFramework/Middleware/PublicShare/PublicShareMiddleware.php
@@ -26,7 +26,6 @@ namespace OC\AppFramework\Middleware\PublicShare;
use OC\AppFramework\Middleware\PublicShare\Exceptions\NeedAuthenticationException;
use OCP\AppFramework\AuthPublicShareController;
use OCP\AppFramework\Http\NotFoundResponse;
-use OCP\AppFramework\Http\Response;
use OCP\AppFramework\Middleware;
use OCP\AppFramework\PublicShareController;
use OCP\Files\NotFoundException;
diff --git a/lib/private/AppFramework/Middleware/Security/FeaturePolicyMiddleware.php b/lib/private/AppFramework/Middleware/Security/FeaturePolicyMiddleware.php
index 67d2480a1f2..63f665f512d 100644
--- a/lib/private/AppFramework/Middleware/Security/FeaturePolicyMiddleware.php
+++ b/lib/private/AppFramework/Middleware/Security/FeaturePolicyMiddleware.php
@@ -26,14 +26,9 @@ declare(strict_types=1);
namespace OC\AppFramework\Middleware\Security;
-use OC\Security\CSP\ContentSecurityPolicyManager;
-use OC\Security\CSP\ContentSecurityPolicyNonceManager;
-use OC\Security\CSRF\CsrfTokenManager;
use OC\Security\FeaturePolicy\FeaturePolicy;
use OC\Security\FeaturePolicy\FeaturePolicyManager;
use OCP\AppFramework\Controller;
-use OCP\AppFramework\Http\ContentSecurityPolicy;
-use OCP\AppFramework\Http\EmptyContentSecurityPolicy;
use OCP\AppFramework\Http\EmptyFeaturePolicy;
use OCP\AppFramework\Http\Response;
use OCP\AppFramework\Middleware;
diff --git a/lib/private/AppFramework/Middleware/SessionMiddleware.php b/lib/private/AppFramework/Middleware/SessionMiddleware.php
index 00ead5f2476..1f4ba123104 100644
--- a/lib/private/AppFramework/Middleware/SessionMiddleware.php
+++ b/lib/private/AppFramework/Middleware/SessionMiddleware.php
@@ -29,7 +29,6 @@ use OC\AppFramework\Utility\ControllerMethodReflector;
use OCP\AppFramework\Controller;
use OCP\AppFramework\Http\Response;
use OCP\AppFramework\Middleware;
-use OCP\IRequest;
use OCP\ISession;
class SessionMiddleware extends Middleware {
diff --git a/lib/private/AppFramework/OCS/BaseResponse.php b/lib/private/AppFramework/OCS/BaseResponse.php
index c7aa5ad073b..d6a30c900cc 100644
--- a/lib/private/AppFramework/OCS/BaseResponse.php
+++ b/lib/private/AppFramework/OCS/BaseResponse.php
@@ -26,7 +26,6 @@ namespace OC\AppFramework\OCS;
use OCP\AppFramework\Http;
use OCP\AppFramework\Http\DataResponse;
-use OCP\AppFramework\Http\EmptyContentSecurityPolicy;
use OCP\AppFramework\Http\Response;
abstract class BaseResponse extends Response {
diff --git a/lib/private/Authentication/Events/ARemoteWipeEvent.php b/lib/private/Authentication/Events/ARemoteWipeEvent.php
index 9dfd740c220..111c6cfeeef 100644
--- a/lib/private/Authentication/Events/ARemoteWipeEvent.php
+++ b/lib/private/Authentication/Events/ARemoteWipeEvent.php
@@ -28,7 +28,6 @@ namespace OC\Authentication\Events;
use OC\Authentication\Token\IToken;
use OCP\EventDispatcher\Event;
-use Symfony\Component\EventDispatcher\GenericEvent;
abstract class ARemoteWipeEvent extends Event {
diff --git a/lib/private/Authentication/Listeners/RemoteWipeActivityListener.php b/lib/private/Authentication/Listeners/RemoteWipeActivityListener.php
index 57ea002c6ab..f7d3693acc9 100644
--- a/lib/private/Authentication/Listeners/RemoteWipeActivityListener.php
+++ b/lib/private/Authentication/Listeners/RemoteWipeActivityListener.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OC\Authentication\Listeners;
use BadMethodCallException;
-use OC\Authentication\Events\ARemoteWipeEvent;
use OC\Authentication\Events\RemoteWipeFinished;
use OC\Authentication\Events\RemoteWipeStarted;
use OC\Authentication\Token\IToken;
diff --git a/lib/private/Authentication/Listeners/RemoteWipeNotificationsListener.php b/lib/private/Authentication/Listeners/RemoteWipeNotificationsListener.php
index f97d8da7351..9eab3e74e9c 100644
--- a/lib/private/Authentication/Listeners/RemoteWipeNotificationsListener.php
+++ b/lib/private/Authentication/Listeners/RemoteWipeNotificationsListener.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OC\Authentication\Listeners;
-use OC\Authentication\Events\ARemoteWipeEvent;
use OC\Authentication\Events\RemoteWipeFinished;
use OC\Authentication\Events\RemoteWipeStarted;
use OC\Authentication\Token\IToken;
diff --git a/lib/private/Authentication/Token/RemoteWipe.php b/lib/private/Authentication/Token/RemoteWipe.php
index e0fbf0734f5..b16246319e1 100644
--- a/lib/private/Authentication/Token/RemoteWipe.php
+++ b/lib/private/Authentication/Token/RemoteWipe.php
@@ -30,7 +30,6 @@ namespace OC\Authentication\Token;
use function array_filter;
use OC\Authentication\Events\RemoteWipeFinished;
use OC\Authentication\Events\RemoteWipeStarted;
-use OC\Authentication\Exceptions\ExpiredTokenException;
use OC\Authentication\Exceptions\InvalidTokenException;
use OC\Authentication\Exceptions\WipeTokenException;
use OCP\EventDispatcher\IEventDispatcher;
diff --git a/lib/private/Authentication/TwoFactorAuth/Manager.php b/lib/private/Authentication/TwoFactorAuth/Manager.php
index b048d4e1f3c..170048f451b 100644
--- a/lib/private/Authentication/TwoFactorAuth/Manager.php
+++ b/lib/private/Authentication/TwoFactorAuth/Manager.php
@@ -31,13 +31,11 @@ use function array_diff;
use function array_filter;
use BadMethodCallException;
use Exception;
-use OC\Authentication\Exceptions\ExpiredTokenException;
use OC\Authentication\Exceptions\InvalidTokenException;
use OC\Authentication\Token\IProvider as TokenProvider;
use OCP\Activity\IManager;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\Authentication\TwoFactorAuth\IActivatableAtLogin;
-use OCP\Authentication\TwoFactorAuth\ILoginSetupProvider;
use OCP\Authentication\TwoFactorAuth\IProvider;
use OCP\Authentication\TwoFactorAuth\IRegistry;
use OCP\IConfig;
diff --git a/lib/private/Authentication/TwoFactorAuth/ProviderManager.php b/lib/private/Authentication/TwoFactorAuth/ProviderManager.php
index 8c41ac30bfd..26c1af0ae17 100644
--- a/lib/private/Authentication/TwoFactorAuth/ProviderManager.php
+++ b/lib/private/Authentication/TwoFactorAuth/ProviderManager.php
@@ -28,7 +28,6 @@ namespace OC\Authentication\TwoFactorAuth;
use OC\Authentication\Exceptions\InvalidProviderException;
use OCP\Authentication\TwoFactorAuth\IActivatableByAdmin;
-use OCP\Authentication\TwoFactorAuth\IDeactivableByAdmin;
use OCP\Authentication\TwoFactorAuth\IDeactivatableByAdmin;
use OCP\Authentication\TwoFactorAuth\IProvider;
use OCP\Authentication\TwoFactorAuth\IRegistry;
diff --git a/lib/private/Collaboration/Resources/Manager.php b/lib/private/Collaboration/Resources/Manager.php
index 82731cbdb44..35ae0330e51 100644
--- a/lib/private/Collaboration/Resources/Manager.php
+++ b/lib/private/Collaboration/Resources/Manager.php
@@ -30,7 +30,6 @@ namespace OC\Collaboration\Resources;
use Doctrine\DBAL\Exception\UniqueConstraintViolationException;
-use OCP\AppFramework\QueryException;
use OCP\Collaboration\Resources\CollectionException;
use OCP\Collaboration\Resources\ICollection;
use OCP\Collaboration\Resources\IManager;
diff --git a/lib/private/DB/AdapterPgSql.php b/lib/private/DB/AdapterPgSql.php
index 6cfd1d458bc..628c91dbb9e 100644
--- a/lib/private/DB/AdapterPgSql.php
+++ b/lib/private/DB/AdapterPgSql.php
@@ -26,7 +26,6 @@
namespace OC\DB;
-use Doctrine\DBAL\DBALException;
class AdapterPgSql extends Adapter {
protected $compatModePre9_5 = null;
diff --git a/lib/private/DB/Connection.php b/lib/private/DB/Connection.php
index 8150f08593f..0795e3299ce 100644
--- a/lib/private/DB/Connection.php
+++ b/lib/private/DB/Connection.php
@@ -41,7 +41,6 @@ use Doctrine\DBAL\Driver;
use Doctrine\DBAL\Exception\ConstraintViolationException;
use Doctrine\DBAL\Platforms\MySqlPlatform;
use Doctrine\DBAL\Schema\Schema;
-use Doctrine\DBAL\TransactionIsolationLevel;
use OC\DB\QueryBuilder\QueryBuilder;
use OCP\DB\QueryBuilder\IQueryBuilder;
use OCP\IDBConnection;
diff --git a/lib/private/DirectEditing/Manager.php b/lib/private/DirectEditing/Manager.php
index 5e3f7755938..e342863d52f 100644
--- a/lib/private/DirectEditing/Manager.php
+++ b/lib/private/DirectEditing/Manager.php
@@ -34,8 +34,6 @@ use OCP\DirectEditing\ACreateFromTemplate;
use OCP\DirectEditing\IEditor;
use \OCP\DirectEditing\IManager;
use OCP\DirectEditing\IToken;
-use OCP\DirectEditing\RegisterDirectEditorEvent;
-use OCP\EventDispatcher\IEventDispatcher;
use OCP\Files\File;
use OCP\Files\IRootFolder;
use OCP\Files\Node;
diff --git a/lib/private/Files/Filesystem.php b/lib/private/Files/Filesystem.php
index 24d21ad6049..06e7db7986f 100644
--- a/lib/private/Files/Filesystem.php
+++ b/lib/private/Files/Filesystem.php
@@ -62,7 +62,6 @@ namespace OC\Files;
use OC\Cache\CappedMemoryCache;
use OC\Files\Config\MountProviderCollection;
use OC\Files\Mount\MountPoint;
-use OC\Files\Storage\StorageFactory;
use OC\Lockdown\Filesystem\NullStorage;
use OCP\Files\Config\IMountProvider;
use OCP\Files\NotFoundException;
diff --git a/lib/private/Files/Type/Loader.php b/lib/private/Files/Type/Loader.php
index 616994d0c7b..348de2d8844 100644
--- a/lib/private/Files/Type/Loader.php
+++ b/lib/private/Files/Type/Loader.php
@@ -26,7 +26,6 @@
namespace OC\Files\Type;
-use Doctrine\DBAL\Exception\UniqueConstraintViolationException;
use OCP\Files\IMimeTypeLoader;
use OCP\IDBConnection;
diff --git a/lib/private/Lock/DBLockingProvider.php b/lib/private/Lock/DBLockingProvider.php
index 974b0b55c89..a8c22b59cb1 100644
--- a/lib/private/Lock/DBLockingProvider.php
+++ b/lib/private/Lock/DBLockingProvider.php
@@ -28,7 +28,6 @@
namespace OC\Lock;
-use Doctrine\DBAL\Exception\UniqueConstraintViolationException;
use OC\DB\QueryBuilder\Literal;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\DB\QueryBuilder\IQueryBuilder;
diff --git a/lib/private/Log/Systemdlog.php b/lib/private/Log/Systemdlog.php
index 5dc6ab875b8..e74cab40fd6 100644
--- a/lib/private/Log/Systemdlog.php
+++ b/lib/private/Log/Systemdlog.php
@@ -27,7 +27,6 @@ namespace OC\Log;
use OC\HintException;
use OC\SystemConfig;
-use OCP\IConfig;
use OCP\ILogger;
use OCP\Log\IWriter;
diff --git a/lib/private/Preview/Generator.php b/lib/private/Preview/Generator.php
index dcd4ccd130c..bb597460f9d 100644
--- a/lib/private/Preview/Generator.php
+++ b/lib/private/Preview/Generator.php
@@ -26,7 +26,6 @@
namespace OC\Preview;
-use OC\Preview\GeneratorHelper;
use OCP\Files\File;
use OCP\Files\IAppData;
use OCP\Files\NotFoundException;
@@ -36,7 +35,6 @@ use OCP\Files\SimpleFS\ISimpleFolder;
use OCP\IConfig;
use OCP\IImage;
use OCP\IPreview;
-use OCP\Preview\IProvider;
use OCP\Preview\IProviderV2;
use OCP\Preview\IVersionedPreviewFile;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
diff --git a/lib/private/Preview/GeneratorHelper.php b/lib/private/Preview/GeneratorHelper.php
index 470cad2d0a6..28611005b29 100644
--- a/lib/private/Preview/GeneratorHelper.php
+++ b/lib/private/Preview/GeneratorHelper.php
@@ -25,7 +25,6 @@
namespace OC\Preview;
-use OC\Files\View;
use OCP\Files\File;
use OCP\Files\IRootFolder;
use OCP\Files\SimpleFS\ISimpleFile;
diff --git a/lib/private/Session/Internal.php b/lib/private/Session/Internal.php
index b9aae76c3b0..7990c4a7dae 100644
--- a/lib/private/Session/Internal.php
+++ b/lib/private/Session/Internal.php
@@ -36,8 +36,6 @@ namespace OC\Session;
use OC\Authentication\Exceptions\InvalidTokenException;
use OC\Authentication\Token\IProvider;
-use OC\SystemConfig;
-use OCP\IConfig;
use OCP\Session\Exceptions\SessionNotAvailableException;
/**
diff --git a/lib/private/Settings/Manager.php b/lib/private/Settings/Manager.php
index ed1d2f45cd7..d9f50185620 100644
--- a/lib/private/Settings/Manager.php
+++ b/lib/private/Settings/Manager.php
@@ -33,7 +33,6 @@
namespace OC\Settings;
use Closure;
-use OC\Settings\Personal\PersonalInfo;
use OCP\AppFramework\QueryException;
use OCP\IL10N;
use OCP\ILogger;
diff --git a/lib/private/Setup.php b/lib/private/Setup.php
index 26299aaa039..2fffdfbb214 100644
--- a/lib/private/Setup.php
+++ b/lib/private/Setup.php
@@ -59,7 +59,6 @@ use OCP\Defaults;
use OCP\IGroup;
use OCP\IL10N;
use OCP\ILogger;
-use OCP\IUser;
use OCP\Security\ISecureRandom;
class Setup {
diff --git a/lib/private/Share/Share.php b/lib/private/Share/Share.php
index ed876022bdd..2e328970b8b 100644
--- a/lib/private/Share/Share.php
+++ b/lib/private/Share/Share.php
@@ -37,9 +37,7 @@
namespace OC\Share;
use OCP\DB\QueryBuilder\IQueryBuilder;
-use OCP\IConfig;
use OCP\ILogger;
-use OCP\Util;
/**
* This class provides the ability for apps to share their content between users.
diff --git a/lib/private/Share20/DefaultShareProvider.php b/lib/private/Share20/DefaultShareProvider.php
index e7f077f4022..3ebe5784cc8 100644
--- a/lib/private/Share20/DefaultShareProvider.php
+++ b/lib/private/Share20/DefaultShareProvider.php
@@ -53,7 +53,6 @@ use OCP\IUserManager;
use OCP\Mail\IMailer;
use OCP\Share\Exceptions\ShareNotFound;
use OCP\Share\IShare;
-use OCP\Share\IShareHelper;
use OCP\Share\IShareProvider;
/**
diff --git a/lib/private/Share20/ProviderFactory.php b/lib/private/Share20/ProviderFactory.php
index 5a91202a1d0..cdfd40c8703 100644
--- a/lib/private/Share20/ProviderFactory.php
+++ b/lib/private/Share20/ProviderFactory.php
@@ -36,7 +36,6 @@ use OC\Share20\Exception\ProviderException;
use OCA\FederatedFileSharing\AddressHandler;
use OCA\FederatedFileSharing\FederatedShareProvider;
use OCA\FederatedFileSharing\Notifications;
-use OCA\FederatedFileSharing\OCM\CloudFederationProvider;
use OCA\FederatedFileSharing\TokenHandler;
use OCA\ShareByMail\Settings\SettingsManager;
use OCA\ShareByMail\ShareByMailProvider;
diff --git a/lib/private/User/Database.php b/lib/private/User/Database.php
index 905a66f3797..856959a4596 100644
--- a/lib/private/User/Database.php
+++ b/lib/private/User/Database.php
@@ -72,7 +72,6 @@ use OCP\User\Backend\IGetHomeBackend;
use OCP\User\Backend\IGetRealUIDBackend;
use OCP\User\Backend\ISetDisplayNameBackend;
use OCP\User\Backend\ISetPasswordBackend;
-use Symfony\Component\EventDispatcher\GenericEvent;
/**
* Class for user management in a SQL Database (e.g. MySQL, SQLite)
diff --git a/lib/private/legacy/files.php b/lib/private/legacy/files.php
index adc793ba9b7..dd0fdc90dc0 100644
--- a/lib/private/legacy/files.php
+++ b/lib/private/legacy/files.php
@@ -42,7 +42,6 @@
use OC\Files\View;
use OC\Streamer;
-use OCP\ILogger;
use OCP\Lock\ILockingProvider;
/**
diff --git a/lib/public/AppFramework/Http/Template/ExternalShareMenuAction.php b/lib/public/AppFramework/Http/Template/ExternalShareMenuAction.php
index af112a7076d..7866f19d430 100644
--- a/lib/public/AppFramework/Http/Template/ExternalShareMenuAction.php
+++ b/lib/public/AppFramework/Http/Template/ExternalShareMenuAction.php
@@ -26,7 +26,6 @@
namespace OCP\AppFramework\Http\Template;
-use OCP\AppFramework\Http\Template\SimpleMenuAction;
use OCP\Util;
/**
diff --git a/lib/public/AppFramework/Http/Template/LinkMenuAction.php b/lib/public/AppFramework/Http/Template/LinkMenuAction.php
index 1ddb1a46e94..489a7d534ad 100644
--- a/lib/public/AppFramework/Http/Template/LinkMenuAction.php
+++ b/lib/public/AppFramework/Http/Template/LinkMenuAction.php
@@ -24,7 +24,6 @@
namespace OCP\AppFramework\Http\Template;
-use OCP\AppFramework\Http\Template\SimpleMenuAction;
use OCP\Util;
/**
diff --git a/lib/public/Group/Events/BeforeGroupCreatedEvent.php b/lib/public/Group/Events/BeforeGroupCreatedEvent.php
index b9bb1788f84..3385d1a9397 100644
--- a/lib/public/Group/Events/BeforeGroupCreatedEvent.php
+++ b/lib/public/Group/Events/BeforeGroupCreatedEvent.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OCP\Group\Events;
use OCP\EventDispatcher\Event;
-use OCP\IGroup;
/**
* @since 18.0.0
diff --git a/lib/public/IUser.php b/lib/public/IUser.php
index c05403cc236..a5e94bf8ac4 100644
--- a/lib/public/IUser.php
+++ b/lib/public/IUser.php
@@ -28,7 +28,6 @@
namespace OCP;
-use OCP\UserInterface;
/**
* Interface IUser
diff --git a/lib/public/Share/IProviderFactory.php b/lib/public/Share/IProviderFactory.php
index 120d46258ff..b2587459d85 100644
--- a/lib/public/Share/IProviderFactory.php
+++ b/lib/public/Share/IProviderFactory.php
@@ -24,7 +24,6 @@
namespace OCP\Share;
use OC\Share20\Exception\ProviderException;
-use OCP\IServerContainer;
/**
* Interface IProviderFactory
diff --git a/lib/public/User/Events/BeforeUserLoggedInWithCookieEvent.php b/lib/public/User/Events/BeforeUserLoggedInWithCookieEvent.php
index fd7463bc0f9..1bcf3231829 100644
--- a/lib/public/User/Events/BeforeUserLoggedInWithCookieEvent.php
+++ b/lib/public/User/Events/BeforeUserLoggedInWithCookieEvent.php
@@ -27,7 +27,6 @@ declare(strict_types=1);
namespace OCP\User\Events;
use OCP\EventDispatcher\Event;
-use OCP\IUser;
/**
* @since 18.0.0
diff --git a/tests/Core/Command/Maintenance/UpdateTheme.php b/tests/Core/Command/Maintenance/UpdateTheme.php
index ace756b2647..bb6f5f45095 100644
--- a/tests/Core/Command/Maintenance/UpdateTheme.php
+++ b/tests/Core/Command/Maintenance/UpdateTheme.php
@@ -23,12 +23,9 @@
namespace Tests\Core\Command\Maintenance;
-use OC\Core\Command\Maintenance\Mimetype\UpdateDB;
use OC\Core\Command\Maintenance\UpdateTheme;
use OC\Files\Type\Detection;
-use OC\Files\Type\Loader;
use OCP\Files\IMimeTypeDetector;
-use OCP\Files\IMimeTypeLoader;
use OCP\ICache;
use OCP\ICacheFactory;
use Symfony\Component\Console\Input\InputInterface;
diff --git a/tests/Core/Controller/OCSControllerTest.php b/tests/Core/Controller/OCSControllerTest.php
index f0fbce86b8c..96339cbf5e1 100644
--- a/tests/Core/Controller/OCSControllerTest.php
+++ b/tests/Core/Controller/OCSControllerTest.php
@@ -24,7 +24,6 @@
namespace OC\Core\Controller;
use OC\CapabilitiesManager;
-use OC\Security\Bruteforce\Throttler;
use OC\Security\IdentityProof\Key;
use OC\Security\IdentityProof\Manager;
use OCP\AppFramework\Http\DataResponse;
diff --git a/tests/acceptance/features/bootstrap/FileListAncestorSetter.php b/tests/acceptance/features/bootstrap/FileListAncestorSetter.php
index 2f8d3ad00e5..d914edf234f 100644
--- a/tests/acceptance/features/bootstrap/FileListAncestorSetter.php
+++ b/tests/acceptance/features/bootstrap/FileListAncestorSetter.php
@@ -21,7 +21,6 @@
*
*/
-use Behat\Behat\Context\Context;
use Behat\Behat\Hook\Scope\BeforeScenarioScope;
/**
diff --git a/tests/lib/App/CodeChecker/InfoCheckerTest.php b/tests/lib/App/CodeChecker/InfoCheckerTest.php
index 531066a54c6..3b5060ae694 100644
--- a/tests/lib/App/CodeChecker/InfoCheckerTest.php
+++ b/tests/lib/App/CodeChecker/InfoCheckerTest.php
@@ -22,7 +22,6 @@
namespace Test\App\CodeChecker;
use OC\App\CodeChecker\InfoChecker;
-use OC\App\InfoParser;
use Test\TestCase;
class InfoCheckerTest extends TestCase {
diff --git a/tests/lib/AppFramework/Controller/AuthPublicShareControllerTest.php b/tests/lib/AppFramework/Controller/AuthPublicShareControllerTest.php
index 8eb76d3cb27..b2d31205f94 100644
--- a/tests/lib/AppFramework/Controller/AuthPublicShareControllerTest.php
+++ b/tests/lib/AppFramework/Controller/AuthPublicShareControllerTest.php
@@ -23,16 +23,9 @@
namespace Test\AppFramework\Controller;
-use OC\AppFramework\Middleware\PublicShare\Exceptions\NeedAuthenticationException;
-use OC\AppFramework\Middleware\PublicShare\PublicShareMiddleware;
use OCP\AppFramework\AuthPublicShareController;
-use OCP\AppFramework\Controller;
-use OCP\AppFramework\Http\NotFoundResponse;
use OCP\AppFramework\Http\RedirectResponse;
use OCP\AppFramework\Http\TemplateResponse;
-use OCP\AppFramework\PublicShareController;
-use OCP\Files\NotFoundException;
-use OCP\IConfig;
use OCP\IRequest;
use OCP\ISession;
use OCP\IURLGenerator;
diff --git a/tests/lib/AppFramework/Controller/ControllerTest.php b/tests/lib/AppFramework/Controller/ControllerTest.php
index b1cb1ceab6f..8f4a9ee46d4 100644
--- a/tests/lib/AppFramework/Controller/ControllerTest.php
+++ b/tests/lib/AppFramework/Controller/ControllerTest.php
@@ -27,7 +27,6 @@ use OC\AppFramework\Http\Request;
use OCP\AppFramework\Controller;
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\Http\JSONResponse;
-use OCP\AppFramework\Http\TemplateResponse;
use OCP\IConfig;
class ChildController extends Controller {
diff --git a/tests/lib/AppFramework/Controller/PublicShareControllerTest.php b/tests/lib/AppFramework/Controller/PublicShareControllerTest.php
index 318647ca844..388d5fbeef2 100644
--- a/tests/lib/AppFramework/Controller/PublicShareControllerTest.php
+++ b/tests/lib/AppFramework/Controller/PublicShareControllerTest.php
@@ -23,18 +23,9 @@
namespace Test\AppFramework\Controller;
-use OC\AppFramework\Middleware\PublicShare\Exceptions\NeedAuthenticationException;
-use OC\AppFramework\Middleware\PublicShare\PublicShareMiddleware;
-use OCP\AppFramework\AuthPublicShareController;
-use OCP\AppFramework\Controller;
-use OCP\AppFramework\Http\NotFoundResponse;
-use OCP\AppFramework\Http\RedirectResponse;
use OCP\AppFramework\PublicShareController;
-use OCP\Files\NotFoundException;
-use OCP\IConfig;
use OCP\IRequest;
use OCP\ISession;
-use OCP\IURLGenerator;
class PublicShareControllerTest extends \Test\TestCase {
diff --git a/tests/lib/AppFramework/Http/ContentSecurityPolicyTest.php b/tests/lib/AppFramework/Http/ContentSecurityPolicyTest.php
index 6acc21550d1..0c8d125d960 100644
--- a/tests/lib/AppFramework/Http/ContentSecurityPolicyTest.php
+++ b/tests/lib/AppFramework/Http/ContentSecurityPolicyTest.php
@@ -8,7 +8,6 @@
namespace Test\AppFramework\Http;
-use OCP\AppFramework\Http;
use OCP\AppFramework\Http\ContentSecurityPolicy;
/**
diff --git a/tests/lib/AppFramework/Http/EmptyContentSecurityPolicyTest.php b/tests/lib/AppFramework/Http/EmptyContentSecurityPolicyTest.php
index c19caad23c7..121bb904d18 100644
--- a/tests/lib/AppFramework/Http/EmptyContentSecurityPolicyTest.php
+++ b/tests/lib/AppFramework/Http/EmptyContentSecurityPolicyTest.php
@@ -8,7 +8,6 @@
namespace Test\AppFramework\Http;
-use OCP\AppFramework\Http;
use OCP\AppFramework\Http\EmptyContentSecurityPolicy;
/**
diff --git a/tests/lib/AppFramework/Middleware/MiddlewareDispatcherTest.php b/tests/lib/AppFramework/Middleware/MiddlewareDispatcherTest.php
index 965637cb4c4..af68961b183 100644
--- a/tests/lib/AppFramework/Middleware/MiddlewareDispatcherTest.php
+++ b/tests/lib/AppFramework/Middleware/MiddlewareDispatcherTest.php
@@ -25,7 +25,6 @@ namespace Test\AppFramework\Middleware;
use OC\AppFramework\Http\Request;
use OC\AppFramework\Middleware\MiddlewareDispatcher;
-use OCP\AppFramework\Controller;
use OCP\AppFramework\Http\Response;
use OCP\AppFramework\Middleware;
use OCP\IConfig;
diff --git a/tests/lib/AppFramework/Middleware/Security/BruteForceMiddlewareTest.php b/tests/lib/AppFramework/Middleware/Security/BruteForceMiddlewareTest.php
index f6ce5c27b22..55c874ccdb5 100644
--- a/tests/lib/AppFramework/Middleware/Security/BruteForceMiddlewareTest.php
+++ b/tests/lib/AppFramework/Middleware/Security/BruteForceMiddlewareTest.php
@@ -26,7 +26,6 @@ use OC\AppFramework\Utility\ControllerMethodReflector;
use OC\Security\Bruteforce\Throttler;
use OCP\AppFramework\Controller;
use OCP\AppFramework\Http\Response;
-use OCP\Http\Client\IResponse;
use OCP\IRequest;
use Test\TestCase;
diff --git a/tests/lib/AppFramework/Middleware/Security/FeaturePolicyMiddlewareTest.php b/tests/lib/AppFramework/Middleware/Security/FeaturePolicyMiddlewareTest.php
index e136d783616..62be8037cfc 100644
--- a/tests/lib/AppFramework/Middleware/Security/FeaturePolicyMiddlewareTest.php
+++ b/tests/lib/AppFramework/Middleware/Security/FeaturePolicyMiddlewareTest.php
@@ -25,12 +25,9 @@ declare(strict_types=1);
namespace Test\AppFramework\Middleware\Security;
use OC\AppFramework\Middleware\Security\FeaturePolicyMiddleware;
-use OC\Security\CSP\ContentSecurityPolicy;
-use OC\Security\CSRF\CsrfToken;
use OC\Security\FeaturePolicy\FeaturePolicy;
use OC\Security\FeaturePolicy\FeaturePolicyManager;
use OCP\AppFramework\Controller;
-use OCP\AppFramework\Http\EmptyContentSecurityPolicy;
use OCP\AppFramework\Http\EmptyFeaturePolicy;
use OCP\AppFramework\Http\Response;
use PHPUnit\Framework\MockObject\MockObject;
diff --git a/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php b/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php
index ae0e6ff484d..fb6dee20065 100644
--- a/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php
+++ b/tests/lib/AppFramework/Middleware/Security/SecurityMiddlewareTest.php
@@ -32,17 +32,10 @@ use OC\AppFramework\Middleware\Security\Exceptions\SecurityException;
use OC\Appframework\Middleware\Security\Exceptions\StrictCookieMissingException;
use OC\AppFramework\Middleware\Security\SecurityMiddleware;
use OC\AppFramework\Utility\ControllerMethodReflector;
-use OC\Security\CSP\ContentSecurityPolicy;
-use OC\Security\CSP\ContentSecurityPolicyManager;
-use OC\Security\CSP\ContentSecurityPolicyNonceManager;
-use OC\Security\CSRF\CsrfToken;
-use OC\Security\CSRF\CsrfTokenManager;
use OCP\App\IAppManager;
use OCP\AppFramework\Controller;
-use OCP\AppFramework\Http\EmptyContentSecurityPolicy;
use OCP\AppFramework\Http\JSONResponse;
use OCP\AppFramework\Http\RedirectResponse;
-use OCP\AppFramework\Http\Response;
use OCP\AppFramework\Http\TemplateResponse;
use OCP\IConfig;
use OCP\IL10N;
diff --git a/tests/lib/AppFramework/Middleware/SessionMiddlewareTest.php b/tests/lib/AppFramework/Middleware/SessionMiddlewareTest.php
index db2a9d5b625..940112311c3 100644
--- a/tests/lib/AppFramework/Middleware/SessionMiddlewareTest.php
+++ b/tests/lib/AppFramework/Middleware/SessionMiddlewareTest.php
@@ -11,12 +11,10 @@
namespace Test\AppFramework\Middleware;
-use OC\AppFramework\Http\Request;
use OC\AppFramework\Middleware\SessionMiddleware;
use OC\AppFramework\Utility\ControllerMethodReflector;
use OCP\AppFramework\Controller;
use OCP\AppFramework\Http\Response;
-use OCP\IConfig;
class SessionMiddlewareTest extends \Test\TestCase {
diff --git a/tests/lib/Authentication/Listeners/RemoteWipeActivityListenerTest.php b/tests/lib/Authentication/Listeners/RemoteWipeActivityListenerTest.php
index 47d1d53a74c..4f203b368c0 100644
--- a/tests/lib/Authentication/Listeners/RemoteWipeActivityListenerTest.php
+++ b/tests/lib/Authentication/Listeners/RemoteWipeActivityListenerTest.php
@@ -32,7 +32,6 @@ use OCP\Activity\IManager as IActivityManager;
use OCP\EventDispatcher\Event;
use OCP\EventDispatcher\IEventListener;
use OCP\ILogger;
-use OCP\IUser;
use PHPUnit\Framework\MockObject\MockObject;
use Test\TestCase;
diff --git a/tests/lib/Authentication/Login/ClearLostPasswordTokensCommandTest.php b/tests/lib/Authentication/Login/ClearLostPasswordTokensCommandTest.php
index 0d3b7acfa2d..9c14c2a3fb2 100644
--- a/tests/lib/Authentication/Login/ClearLostPasswordTokensCommandTest.php
+++ b/tests/lib/Authentication/Login/ClearLostPasswordTokensCommandTest.php
@@ -27,7 +27,6 @@ namespace Test\Authentication\Login;
use lib\Authentication\Login\ALoginCommandTest;
use OC\Authentication\Login\ClearLostPasswordTokensCommand;
-use OC\Authentication\Login\LoginData;
use OCP\IConfig;
use PHPUnit\Framework\MockObject\MockObject;
diff --git a/tests/lib/Authentication/Login/UidLoginCommandTest.php b/tests/lib/Authentication/Login/UidLoginCommandTest.php
index c4dd3f10381..1d477921677 100644
--- a/tests/lib/Authentication/Login/UidLoginCommandTest.php
+++ b/tests/lib/Authentication/Login/UidLoginCommandTest.php
@@ -25,7 +25,6 @@ declare(strict_types=1);
namespace lib\Authentication\Login;
-use OC\Authentication\Login\UidCheckCommand;
use OC\Authentication\Login\UidLoginCommand;
use OC\User\Manager;
use PHPUnit\Framework\MockObject\MockObject;
diff --git a/tests/lib/Authentication/Token/ManagerTest.php b/tests/lib/Authentication/Token/ManagerTest.php
index 6f64424364e..8cac7d5be5c 100644
--- a/tests/lib/Authentication/Token/ManagerTest.php
+++ b/tests/lib/Authentication/Token/ManagerTest.php
@@ -29,7 +29,6 @@ use OC\Authentication\Exceptions\InvalidTokenException;
use OC\Authentication\Exceptions\PasswordlessTokenException;
use OC\Authentication\Token\DefaultToken;
use OC\Authentication\Token\DefaultTokenProvider;
-use OC\Authentication\Token\ExpiredTokenException;
use OC\Authentication\Token\IToken;
use OC\Authentication\Token\Manager;
use OC\Authentication\Token\PublicKeyToken;
diff --git a/tests/lib/Authentication/TwoFactorAuth/ManagerTest.php b/tests/lib/Authentication/TwoFactorAuth/ManagerTest.php
index 63d0e993f3b..0d5bfeed269 100644
--- a/tests/lib/Authentication/TwoFactorAuth/ManagerTest.php
+++ b/tests/lib/Authentication/TwoFactorAuth/ManagerTest.php
@@ -22,7 +22,6 @@
namespace Test\Authentication\TwoFactorAuth;
-use Exception;
use OC;
use OC\Authentication\Token\IProvider as TokenProvider;
use OC\Authentication\TwoFactorAuth\Manager;
diff --git a/tests/lib/Authentication/TwoFactorAuth/ProviderLoaderTest.php b/tests/lib/Authentication/TwoFactorAuth/ProviderLoaderTest.php
index f3762976837..bff4a33dffc 100644
--- a/tests/lib/Authentication/TwoFactorAuth/ProviderLoaderTest.php
+++ b/tests/lib/Authentication/TwoFactorAuth/ProviderLoaderTest.php
@@ -25,7 +25,6 @@ declare(strict_types=1);
namespace lib\Authentication\TwoFactorAuth;
-use Exception;
use OC\Authentication\TwoFactorAuth\ProviderLoader;
use OCP\App\IAppManager;
use OCP\Authentication\TwoFactorAuth\IProvider;
diff --git a/tests/lib/Collaboration/Collaborators/SearchResultTest.php b/tests/lib/Collaboration/Collaborators/SearchResultTest.php
index 43672345226..3d09a9b632d 100644
--- a/tests/lib/Collaboration/Collaborators/SearchResultTest.php
+++ b/tests/lib/Collaboration/Collaborators/SearchResultTest.php
@@ -27,10 +27,8 @@ namespace Test\Collaboration\Collaborators;
use OC\Collaboration\Collaborators\Search;
use OC\Collaboration\Collaborators\SearchResult;
use OCP\Collaboration\Collaborators\ISearch;
-use OCP\Collaboration\Collaborators\ISearchPlugin;
use OCP\Collaboration\Collaborators\SearchResultType;
use OCP\IContainer;
-use OCP\Share;
use Test\TestCase;
class SearchResultTest extends TestCase {
diff --git a/tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php b/tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php
index 10584812c41..e88acb915d7 100644
--- a/tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php
+++ b/tests/lib/Contacts/ContactsMenu/ActionProviderStoreTest.php
@@ -24,7 +24,6 @@
namespace Tests\Contacts\ContactsMenu;
-use Exception;
use OC\App\AppManager;
use OC\Contacts\ContactsMenu\ActionProviderStore;
use OC\Contacts\ContactsMenu\Providers\EMailProvider;
diff --git a/tests/lib/DirectEditing/ManagerTest.php b/tests/lib/DirectEditing/ManagerTest.php
index 737a41425e1..004292eb47f 100644
--- a/tests/lib/DirectEditing/ManagerTest.php
+++ b/tests/lib/DirectEditing/ManagerTest.php
@@ -12,7 +12,6 @@ use OCP\DirectEditing\IEditor;
use OCP\DirectEditing\IToken;
use OCP\Files\Folder;
use OCP\Files\IRootFolder;
-use OCP\Files\NotFoundException;
use OCP\IDBConnection;
use OCP\IL10N;
use OCP\IUserSession;
diff --git a/tests/lib/Encryption/DecryptAllTest.php b/tests/lib/Encryption/DecryptAllTest.php
index e2c76db7ed9..3365b1fedca 100644
--- a/tests/lib/Encryption/DecryptAllTest.php
+++ b/tests/lib/Encryption/DecryptAllTest.php
@@ -33,7 +33,6 @@ use OCP\UserInterface;
use Symfony\Component\Console\Formatter\OutputFormatterInterface;
use Symfony\Component\Console\Helper\ProgressBar;
use Symfony\Component\Console\Input\InputInterface;
-use Symfony\Component\Console\Output\ConsoleOutputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Test\TestCase;
diff --git a/tests/lib/Files/Cache/UpdaterLegacyTest.php b/tests/lib/Files/Cache/UpdaterLegacyTest.php
index a3b1a428c28..64a901a688e 100644
--- a/tests/lib/Files/Cache/UpdaterLegacyTest.php
+++ b/tests/lib/Files/Cache/UpdaterLegacyTest.php
@@ -9,7 +9,6 @@
namespace Test\Files\Cache;
use OC\Files\Filesystem as Filesystem;
-use OC\Files\Storage\Temporary;
use OC\Files\View;
/**
diff --git a/tests/lib/Files/Cache/UpdaterTest.php b/tests/lib/Files/Cache/UpdaterTest.php
index 8dc5893007b..c6a3c4a3491 100644
--- a/tests/lib/Files/Cache/UpdaterTest.php
+++ b/tests/lib/Files/Cache/UpdaterTest.php
@@ -10,7 +10,6 @@ namespace Test\Files\Cache;
use OC\Files\Filesystem;
use OC\Files\Storage\Temporary;
-use OC\Files\View;
/**
* Class UpdaterTest
diff --git a/tests/lib/Files/EtagTest.php b/tests/lib/Files/EtagTest.php
index d3b372fe137..d315ef3d344 100644
--- a/tests/lib/Files/EtagTest.php
+++ b/tests/lib/Files/EtagTest.php
@@ -10,7 +10,6 @@ namespace Test\Files;
use OC\Files\Filesystem;
use OCP\EventDispatcher\IEventDispatcher;
-use OCP\Share;
use OCA\Files_Sharing\AppInfo\Application;
/**
diff --git a/tests/lib/Files/FileInfoTest.php b/tests/lib/Files/FileInfoTest.php
index 0037941b629..fd2b506beb9 100644
--- a/tests/lib/Files/FileInfoTest.php
+++ b/tests/lib/Files/FileInfoTest.php
@@ -8,11 +8,9 @@
namespace Test\Files;
-use OC\AllConfig;
use OC\Files\FileInfo;
use OC\Files\Storage\Home;
use OC\Files\Storage\Temporary;
-use OC\User\User;
use OCP\IConfig;
use OCP\IUser;
use Test\TestCase;
diff --git a/tests/lib/Files/Node/FolderTest.php b/tests/lib/Files/Node/FolderTest.php
index d33fb4f68f8..a9193cfd672 100644
--- a/tests/lib/Files/Node/FolderTest.php
+++ b/tests/lib/Files/Node/FolderTest.php
@@ -19,7 +19,6 @@ use OC\Files\Node\Root;
use OC\Files\Storage\Temporary;
use OC\Files\Storage\Wrapper\Jail;
use OC\Files\View;
-use OC\User\User;
use OCP\Files\Mount\IMountPoint;
use OCP\Files\NotFoundException;
use OCP\Files\Storage;
diff --git a/tests/lib/Files/Node/NodeTest.php b/tests/lib/Files/Node/NodeTest.php
index 7c8ddee6b5f..25a5fdc27cf 100644
--- a/tests/lib/Files/Node/NodeTest.php
+++ b/tests/lib/Files/Node/NodeTest.php
@@ -11,14 +11,11 @@ namespace Test\Files\Node;
use OC\Files\FileInfo;
use OC\Files\Mount\Manager;
use OC\Files\View;
-use OCP\Files\Config\IUserMountCache;
use OCP\Files\IRootFolder;
use OCP\Files\Node;
use OCP\Files\NotFoundException;
use OCP\Files\Storage;
-use OCP\IConfig;
use OCP\ILogger;
-use OCP\IURLGenerator;
use OCP\IUser;
use OCP\IUserManager;
diff --git a/tests/lib/Files/Node/RootTest.php b/tests/lib/Files/Node/RootTest.php
index 5067236ec58..86cce910f86 100644
--- a/tests/lib/Files/Node/RootTest.php
+++ b/tests/lib/Files/Node/RootTest.php
@@ -13,9 +13,7 @@ use OC\Files\FileInfo;
use OC\Files\Mount\Manager;
use OC\Files\Node\Folder;
use OC\Files\View;
-use OCP\IConfig;
use OCP\ILogger;
-use OCP\IURLGenerator;
use OCP\IUser;
use OCP\IUserManager;
diff --git a/tests/lib/Files/ObjectStore/ObjectStoreStorageTest.php b/tests/lib/Files/ObjectStore/ObjectStoreStorageTest.php
index b8c7b15e039..25ce5525361 100644
--- a/tests/lib/Files/ObjectStore/ObjectStoreStorageTest.php
+++ b/tests/lib/Files/ObjectStore/ObjectStoreStorageTest.php
@@ -20,7 +20,6 @@
namespace Test\Files\ObjectStore;
-use OC\Files\ObjectStore\ObjectStoreStorage;
use OC\Files\ObjectStore\StorageObjectStore;
use OC\Files\Storage\Temporary;
use OCP\Files\ObjectStore\IObjectStore;
diff --git a/tests/lib/Files/SimpleFS/SimpleFileTest.php b/tests/lib/Files/SimpleFS/SimpleFileTest.php
index 07a7e79c7a3..8de5cf50aa3 100644
--- a/tests/lib/Files/SimpleFS/SimpleFileTest.php
+++ b/tests/lib/Files/SimpleFS/SimpleFileTest.php
@@ -27,7 +27,6 @@ use OC\Files\SimpleFS\SimpleFile;
use OCP\Files\File;
use OCP\Files\Folder;
use OCP\Files\NotFoundException;
-use OCP\Files\NotPermittedException;
class SimpleFileTest extends \Test\TestCase {
/** @var File|\PHPUnit_Framework_MockObject_MockObject */
diff --git a/tests/lib/Files/SimpleFS/SimpleFolderTest.php b/tests/lib/Files/SimpleFS/SimpleFolderTest.php
index b902cac77cc..4cab1136d82 100644
--- a/tests/lib/Files/SimpleFS/SimpleFolderTest.php
+++ b/tests/lib/Files/SimpleFS/SimpleFolderTest.php
@@ -25,10 +25,7 @@ namespace Test\File\SimpleFS;
use OC\Files\SimpleFS\SimpleFolder;
use OC\Files\Storage\Temporary;
-use OC\Files\View;
-use OCP\Files\File;
use OCP\Files\Folder;
-use OCP\Files\Node;
use OCP\Files\NotFoundException;
use OCP\Files\SimpleFS\ISimpleFile;
use Test\Traits\MountProviderTrait;
diff --git a/tests/lib/Group/GroupTest.php b/tests/lib/Group/GroupTest.php
index 61e4b39c8f3..e6cd6ca8e6e 100644
--- a/tests/lib/Group/GroupTest.php
+++ b/tests/lib/Group/GroupTest.php
@@ -10,8 +10,6 @@
namespace Test\Group;
use OC\User\User;
-use OCP\IConfig;
-use OCP\IURLGenerator;
use OCP\IUser;
use PHPUnit\Framework\MockObject\MockObject;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
diff --git a/tests/lib/InstallerTest.php b/tests/lib/InstallerTest.php
index 4530784e8e2..7a91fcab270 100644
--- a/tests/lib/InstallerTest.php
+++ b/tests/lib/InstallerTest.php
@@ -9,7 +9,6 @@
namespace Test;
-use OC\App\AppStore\Bundles\Bundle;
use OC\App\AppStore\Fetcher\AppFetcher;
use OC\Archive\ZIP;
use OC\Installer;
diff --git a/tests/lib/Log/LogFactoryTest.php b/tests/lib/Log/LogFactoryTest.php
index 37dbf1d97b8..4a3997dbf20 100644
--- a/tests/lib/Log/LogFactoryTest.php
+++ b/tests/lib/Log/LogFactoryTest.php
@@ -29,7 +29,6 @@ use OC\Log\LogFactory;
use OC\Log\Syslog;
use OC\Log\Systemdlog;
use OC\SystemConfig;
-use OCP\IConfig;
use OCP\IServerContainer;
use Test\TestCase;
diff --git a/tests/lib/Mail/MailerTest.php b/tests/lib/Mail/MailerTest.php
index 1d19929fe00..4c6341eef0f 100644
--- a/tests/lib/Mail/MailerTest.php
+++ b/tests/lib/Mail/MailerTest.php
@@ -22,7 +22,6 @@ use OCP\IL10N;
use OCP\ILogger;
use OCP\IURLGenerator;
use OCP\Mail\Events\BeforeMessageSent;
-use OCP\Mail\IMessage;
use Test\TestCase;
use Swift_SwiftException;
diff --git a/tests/lib/Notification/ManagerTest.php b/tests/lib/Notification/ManagerTest.php
index 6ca83b4b367..a8a94631137 100644
--- a/tests/lib/Notification/ManagerTest.php
+++ b/tests/lib/Notification/ManagerTest.php
@@ -23,10 +23,8 @@ namespace Test\Notification;
use OC\Notification\Manager;
use OCP\ILogger;
-use OCP\Notification\IApp;
use OCP\Notification\IManager;
use OCP\Notification\INotification;
-use OCP\Notification\INotifier;
use OCP\RichObjectStrings\IValidator;
use PHPUnit\Framework\MockObject\MockObject;
use Test\TestCase;
diff --git a/tests/lib/Preview/BackgroundCleanupJobTest.php b/tests/lib/Preview/BackgroundCleanupJobTest.php
index 09c4a16f87a..5536204dd20 100644
--- a/tests/lib/Preview/BackgroundCleanupJobTest.php
+++ b/tests/lib/Preview/BackgroundCleanupJobTest.php
@@ -25,7 +25,6 @@ namespace Test\Preview;
use OC\Files\AppData\Factory;
use OC\Preview\BackgroundCleanupJob;
use OC\PreviewManager;
-use OC\SystemConfig;
use OCP\Files\IRootFolder;
use OCP\IDBConnection;
use Test\Traits\MountProviderTrait;
diff --git a/tests/lib/Preview/GeneratorTest.php b/tests/lib/Preview/GeneratorTest.php
index cfb78a05da5..a36e18fab88 100644
--- a/tests/lib/Preview/GeneratorTest.php
+++ b/tests/lib/Preview/GeneratorTest.php
@@ -33,7 +33,6 @@ use OCP\Files\SimpleFS\ISimpleFolder;
use OCP\IConfig;
use OCP\IImage;
use OCP\IPreview;
-use OCP\Preview\IProvider;
use OCP\Preview\IProviderV2;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
use Symfony\Component\EventDispatcher\GenericEvent;
diff --git a/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php b/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
index 009613fbe32..c4749513140 100644
--- a/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
+++ b/tests/lib/Security/CSP/ContentSecurityPolicyManagerTest.php
@@ -25,8 +25,6 @@ namespace Test\Security\CSP;
use OC\Security\CSP\ContentSecurityPolicyManager;
use OCP\EventDispatcher\IEventDispatcher;
use OCP\Security\CSP\AddContentSecurityPolicyEvent;
-use PHPUnit\Framework\MockObject\MockObject;
-use Symfony\Component\EventDispatcher\EventDispatcher;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
use Test\TestCase;
diff --git a/tests/lib/Security/CertificateManagerTest.php b/tests/lib/Security/CertificateManagerTest.php
index 136c3160413..1dddb2ae092 100644
--- a/tests/lib/Security/CertificateManagerTest.php
+++ b/tests/lib/Security/CertificateManagerTest.php
@@ -8,7 +8,6 @@
namespace Test\Security;
-use OC\Files\Storage\Temporary;
use OC\Files\View;
use OC\Security\CertificateManager;
use OCP\IConfig;
diff --git a/tests/lib/Security/FeaturePolicy/FeaturePolicyManagerTest.php b/tests/lib/Security/FeaturePolicy/FeaturePolicyManagerTest.php
index 179bd6630ba..d2be124a482 100644
--- a/tests/lib/Security/FeaturePolicy/FeaturePolicyManagerTest.php
+++ b/tests/lib/Security/FeaturePolicy/FeaturePolicyManagerTest.php
@@ -24,14 +24,10 @@ declare(strict_types=1);
namespace Test\Security\CSP;
-use OC\Security\CSP\ContentSecurityPolicyManager;
use OC\Security\FeaturePolicy\FeaturePolicyManager;
use OCP\AppFramework\Http\FeaturePolicy;
use OCP\EventDispatcher\IEventDispatcher;
-use OCP\Security\CSP\AddContentSecurityPolicyEvent;
use OCP\Security\FeaturePolicy\AddFeaturePolicyEvent;
-use PHPUnit\Framework\MockObject\MockObject;
-use Symfony\Component\EventDispatcher\EventDispatcher;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
use Test\TestCase;
diff --git a/tests/lib/Security/IdentityProof/ManagerTest.php b/tests/lib/Security/IdentityProof/ManagerTest.php
index aff6d3ed5c7..5f96782bae8 100644
--- a/tests/lib/Security/IdentityProof/ManagerTest.php
+++ b/tests/lib/Security/IdentityProof/ManagerTest.php
@@ -33,7 +33,6 @@ use OCP\ILogger;
use OCP\IUser;
use OCP\Security\ICrypto;
use PHPUnit\Framework\MockObject\MockObject;
-use SebastianBergmann\Comparator\MockObjectComparator;
use Test\TestCase;
class ManagerTest extends TestCase {
diff --git a/tests/lib/Security/RateLimiting/LimiterTest.php b/tests/lib/Security/RateLimiting/LimiterTest.php
index 20b35029050..ea74f476f3c 100644
--- a/tests/lib/Security/RateLimiting/LimiterTest.php
+++ b/tests/lib/Security/RateLimiting/LimiterTest.php
@@ -24,10 +24,7 @@ namespace Test\Security\RateLimiting;
use OC\Security\RateLimiting\Backend\IBackend;
use OC\Security\RateLimiting\Limiter;
use OCP\AppFramework\Utility\ITimeFactory;
-use OCP\ICacheFactory;
-use OCP\IRequest;
use OCP\IUser;
-use OCP\IUserSession;
use Test\TestCase;
class LimiterTest extends TestCase {
diff --git a/tests/lib/Settings/ManagerTest.php b/tests/lib/Settings/ManagerTest.php
index bce547c9a29..c10ad819b3f 100644
--- a/tests/lib/Settings/ManagerTest.php
+++ b/tests/lib/Settings/ManagerTest.php
@@ -24,7 +24,6 @@
namespace OCA\Settings\Tests\AppInfo;
use OC\Settings\Manager;
-use OCA\Settings\Admin\Sharing;
use OCP\IDBConnection;
use OCP\IL10N;
use OCP\ILogger;
diff --git a/tests/lib/Share/ShareTest.php b/tests/lib/Share/ShareTest.php
index af05d0c4bdd..8a1320f79ad 100644
--- a/tests/lib/Share/ShareTest.php
+++ b/tests/lib/Share/ShareTest.php
@@ -23,7 +23,6 @@ namespace Test\Share;
use OC\Share\Share;
use OCP\IGroup;
use OCP\IGroupManager;
-use OCP\ILogger;
use OCP\IUser;
use OCP\IUserManager;
diff --git a/tests/lib/SystemTag/SystemTagManagerTest.php b/tests/lib/SystemTag/SystemTagManagerTest.php
index a5a54fce09f..e0bc41c8b6b 100644
--- a/tests/lib/SystemTag/SystemTagManagerTest.php
+++ b/tests/lib/SystemTag/SystemTagManagerTest.php
@@ -15,7 +15,6 @@ use OC\SystemTag\SystemTagObjectMapper;
use OCP\IDBConnection;
use OCP\IGroupManager;
use OCP\IUser;
-use OCP\IUserManager;
use OCP\SystemTag\ISystemTag;
use OCP\SystemTag\ISystemTagManager;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
diff --git a/tests/lib/Template/IconsCacherTest.php b/tests/lib/Template/IconsCacherTest.php
index 8e36426393f..488fe9c045f 100644
--- a/tests/lib/Template/IconsCacherTest.php
+++ b/tests/lib/Template/IconsCacherTest.php
@@ -27,16 +27,10 @@ namespace Test\Template;
use OC\Files\AppData\AppData;
use OC\Files\AppData\Factory;
use OC\Template\IconsCacher;
-use OC_App;
-use OCA\Theming\ThemingDefaults;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\Files\IAppData;
-use OCP\Files\NotFoundException;
use OCP\Files\SimpleFS\ISimpleFile;
use OCP\Files\SimpleFS\ISimpleFolder;
-use OCP\ICache;
-use OCP\ICacheFactory;
-use OCP\IConfig;
use OCP\ILogger;
use OCP\IURLGenerator;
diff --git a/tests/lib/Template/JSCombinerTest.php b/tests/lib/Template/JSCombinerTest.php
index b12124ea5a9..45d4d4d0275 100644
--- a/tests/lib/Template/JSCombinerTest.php
+++ b/tests/lib/Template/JSCombinerTest.php
@@ -23,7 +23,6 @@
namespace Test\Template;
-use function foo\func;
use OC\SystemConfig;
use OC\Template\JSCombiner;
use OCP\Files\IAppData;
diff --git a/tests/lib/Template/SCSSCacherTest.php b/tests/lib/Template/SCSSCacherTest.php
index 6f9fdf1e7fb..472698fbfee 100644
--- a/tests/lib/Template/SCSSCacherTest.php
+++ b/tests/lib/Template/SCSSCacherTest.php
@@ -27,7 +27,6 @@ use OC\Files\AppData\AppData;
use OC\Files\AppData\Factory;
use OC\Template\IconsCacher;
use OC\Template\SCSSCacher;
-use OC_App;
use OCA\Theming\ThemingDefaults;
use OCP\AppFramework\Utility\ITimeFactory;
use OCP\Files\IAppData;