diff --git a/apps/accessibility/lib/Controller/ConfigController.php b/apps/accessibility/lib/Controller/ConfigController.php index a84281501c..750a1fbe11 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 7addd27e18..cd2b333c23 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 eab5a842fa..6610b56b68 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 63d4b06b42..7223019b96 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 674034cbe4..3a7e0111f6 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 46e3a95d95..c554b2b6d2 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 e3147062b1..7a46060290 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 29f5f113ef..806d0f13a0 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 bad549960d..5a25fbaa22 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 a057e29eb2..3b53487fac 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 4410a7486b..1299d935c5 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 fc7d123a27..768486a07e 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 1c43190c4e..f74a5062c2 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 f178b2fbfb..225024a113 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 41b85f162c..6be21eda3f 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 305ce5154a..39bee3a665 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 48cc054037..67b42aad91 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 8b0408a461..81fb63dd85 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 12796334d6..c2604c8e27 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 737e7e0b55..6778a30b8a 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 f0357f203e..99c4db3dfc 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 364286edd4..53cdad1ad6 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 88300e2ffe..6a49909902 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 2d04c605fc..3b20acd6df 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 92ccbfb08f..0003b5bb6b 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 7e8ee32cec..28f44fbf1c 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 148e7627af..a31968377f 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 b1da96f4c0..7b65009cb3 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 251ce88457..9298edb53a 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 110e8ad7bf..0c129b0de7 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 42e24be5cd..7d2fdc6b15 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 56ad3b36f7..c1acc22f13 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 3769399b62..07396f6f53 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 811c4cac28..a6b89b2137 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 45aab9af1f..ea3f2e51b0 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 2f8dec6248..7d06eecea8 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 a880e89847..c9bdb2627c 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 5d7909a3e9..fee9195cf1 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 a76d5f7d56..b949034270 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 c0c9ce9bc8..bf2948b0f6 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 805b79f439..a99dfb5580 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 7e6d5521fd..ad5c4e1b77 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 9e6b6b550f..3819e07909 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 099c65f73e..ccef73b6a0 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 604408eee1..529eb7cbc7 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 b756386a2b..979894ec0c 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 5a79c49fec..a48de62e69 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 761eeff113..47f52fbcb8 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 5b574d8cd0..fc9b099219 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 e2d6c6848c..86238b542b 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 8802e7b82b..5fef0d3ac3 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 f784a72669..b829525b51 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 076b3a381f..d0c2296f0d 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 14ed904114..63c96151eb 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 b487aab6d7..3efb4e25ee 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 831e37e7e0..cb9e20bb86 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 de168c43f5..4f0b547e43 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 8ea72943be..c9f024cd67 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 e6954a7e0b..59f1b1d8c5 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 a32b42429a..b1088f1322 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 e27400372d..53619c6e85 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 c9f1a928f3..9cf154e9bf 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 478dfa3971..e0d7ea50ac 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 d5f8eb1330..8d75ac2165 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 e682d0dd51..2e20653838 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 c45e7c4a24..cb2e0abb0c 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 eef12dcfd1..89f379e3c1 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 eeb5453e9a..e2ad562e8b 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 d526df6996..dd7e5f9639 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 e5461d2307..084bb25da8 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 e07a1816c3..7517ec88e4 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 4d837500c4..96c8734129 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 7f6d74e5fc..405044746a 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 cfbe35eb20..cb9435e493 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 7352ac0ec6..ca6a594752 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 980e579d36..080f866ae5 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 a6371c37a9..7e2fc51416 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 d043c64f85..6a17b23722 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 7f41e8cc6d..c159c7237e 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 8c5f111ace..608a03e7bd 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 2360006958..fbdadf697e 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 458b602d62..a06cdb8f7a 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 f0f7089b62..969d35f7d2 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 d71e7654cb..4c5d852f95 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 8316e9d922..73883b3eb3 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 c77c6b01d8..ffb456792a 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 8d36e774b0..db2efffc46 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 af5db66795..7ac404be57 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 4bb5bd7164..b656b50ef5 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 dc21255da3..8cab95fc80 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 54008e3def..8f3a699af5 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 f2e49d4dbe..0a073b3948 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 736a3d932f..ce1bd4718f 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 1de5001d13..f38ba17551 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 e3b47b3ef3..71a96eb585 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 092f0326d3..d710b9e502 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 bc54f51cc8..8f522d6f2c 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 4042bb64f5..cf472e0321 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 cace64e4f8..ec03283de5 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 879ac1cff7..c2da7f8d19 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 b658ccbe2e..3a17114261 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 d08bf7b767..1dd3a2cf64 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 b332ee1aa2..3e7215966b 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 f0860f46a3..fe3435d9be 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 302edccf7a..fc589392ac 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 22c430f7a9..eaeaf0dd26 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 995af4de2f..256b42f959 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 d6affe4f09..c0917b1746 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 e2876dd28c..fd0600a3ce 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 0db9571d48..038fd34f43 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 a59e8c2173..1ebf4c8e29 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 131612848c..b6e2611179 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 67d2480a1f..63f665f512 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 00ead5f247..1f4ba12310 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 c7aa5ad073..d6a30c900c 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 9dfd740c22..111c6cfeee 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 57ea002c6a..f7d3693acc 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 f97d8da735..9eab3e74e9 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 e0fbf0734f..b16246319e 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 b048d4e1f3..170048f451 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 8c41ac30bf..26c1af0ae1 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 82731cbdb4..35ae0330e5 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 6cfd1d458b..628c91dbb9 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 8150f08593..0795e3299c 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 5e3f775593..e342863d52 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 24d21ad604..06e7db7986 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 616994d0c7..348de2d884 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 974b0b55c8..a8c22b59cb 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 5dc6ab875b..e74cab40fd 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 dcd4ccd130..bb597460f9 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 470cad2d0a..28611005b2 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 b9aae76c3b..7990c4a7da 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 ed1d2f45cd..d9f5018562 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 26299aaa03..2fffdfbb21 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 ed876022bd..2e328970b8 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 e7f077f402..3ebe5784cc 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 5a91202a1d..cdfd40c870 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 905a66f379..856959a459 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 adc793ba9b..dd0fdc90dc 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 af112a7076..7866f19d43 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 1ddb1a46e9..489a7d534a 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 b9bb1788f8..3385d1a939 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 c05403cc23..a5e94bf8ac 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 120d46258f..b2587459d8 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 fd7463bc0f..1bcf323182 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 ace756b264..bb6f5f4509 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 f0fbce86b8..96339cbf5e 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 2f8d3ad00e..d914edf234 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 531066a54c..3b5060ae69 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 8eb76d3cb2..b2d31205f9 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 b1cb1ceab6..8f4a9ee46d 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 318647ca84..388d5fbeef 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 6acc21550d..0c8d125d96 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 c19caad23c..121bb904d1 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 965637cb4c..af68961b18 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 f6ce5c27b2..55c874ccdb 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 e136d78361..62be8037cf 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 ae0e6ff484..fb6dee2006 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 db2a9d5b62..940112311c 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 47d1d53a74..4f203b368c 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 0d3b7acfa2..9c14c2a3fb 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 c4dd3f1038..1d47792167 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 6f64424364..8cac7d5be5 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 63d0e993f3..0d5bfeed26 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 f376297683..bff4a33dff 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 4367234522..3d09a9b632 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 10584812c4..e88acb915d 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 737a41425e..004292eb47 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 e2c76db7ed..3365b1fedc 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 a3b1a428c2..64a901a688 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 8dc5893007..c6a3c4a349 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 d3b372fe13..d315ef3d34 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 0037941b62..fd2b506beb 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 d33fb4f68f..a9193cfd67 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 7c8ddee6b5..25a5fdc27c 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 5067236ec5..86cce910f8 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 b8c7b15e03..25ce552536 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 07a7e79c7a..8de5cf50aa 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 b902cac77c..4cab1136d8 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 61e4b39c8f..e6cd6ca8e6 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 4530784e8e..7a91fcab27 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 37dbf1d97b..4a3997dbf2 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 1d19929fe0..4c6341eef0 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 6ca83b4b36..a8a9463113 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 09c4a16f87..5536204dd2 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 cfb78a05da..a36e18fab8 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 009613fbe3..c474951314 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 136c316041..1dddb2ae09 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 179bd6630b..d2be124a48 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 aff6d3ed5c..5f96782bae 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 20b3502905..ea74f476f3 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 bce547c9a2..c10ad819b3 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 af05d0c4bd..8a1320f79a 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 a5a54fce09..e0bc41c8b6 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 8e36426393..488fe9c045 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 b12124ea5a..45d4d4d027 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 6f9fdf1e7f..472698fbfe 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;