diff --git a/lib/BackgroundJob/QuotaJob.php b/lib/BackgroundJob/QuotaJob.php index d79baed675..17c78fb705 100644 --- a/lib/BackgroundJob/QuotaJob.php +++ b/lib/BackgroundJob/QuotaJob.php @@ -8,7 +8,6 @@ namespace OCA\Mail\BackgroundJob; -use OCA\Mail\Account; use OCA\Mail\Contracts\IMailManager; use OCA\Mail\Service\AccountService; use OCP\AppFramework\Db\DoesNotExistException; @@ -54,7 +53,6 @@ public function __construct(ITimeFactory $time, protected function run($argument): void { $accountId = (int)$argument['accountId']; try { - /** @var Account $account */ $account = $this->accountService->findById($accountId); } catch (DoesNotExistException $e) { $this->logger->debug('Could not find account <' . $accountId . '> removing from jobs'); diff --git a/lib/IMAP/MailboxSync.php b/lib/IMAP/MailboxSync.php index e26ecf749c..3b6e2dea74 100644 --- a/lib/IMAP/MailboxSync.php +++ b/lib/IMAP/MailboxSync.php @@ -260,7 +260,6 @@ private function isMailboxShared(?Horde_Imap_Client_Namespace_List $namespaces, private function syncMailboxStatus(mixed $mailboxes, ?string $personalNamespace, \Horde_Imap_Client_Socket $client): void { /** @var array{0: Mailbox[], 1: Mailbox[]} */ [$sync, $doNotSync] = array_reduce($mailboxes, function (array $carry, Mailbox $mailbox) use ($personalNamespace): array { - /** @var array{0: Mailbox[], 1: Mailbox[]} $carry */ [$sync, $doNotSync] = $carry; $inboxName = $personalNamespace === null ? 'INBOX' : ($personalNamespace . $mailbox->getDelimiter() . 'INBOX'); if ($inboxName === $mailbox->getName() || $mailbox->getSyncInBackground()) { diff --git a/lib/Listener/NewMessagesNotifier.php b/lib/Listener/NewMessagesNotifier.php index c6be5db3d9..304a676876 100644 --- a/lib/Listener/NewMessagesNotifier.php +++ b/lib/Listener/NewMessagesNotifier.php @@ -8,7 +8,6 @@ namespace OCA\Mail\Listener; -use OCA\Mail\Db\Message; use OCA\Mail\Events\NewMessageReceivedEvent; use OCA\Mail\Events\NewMessagesSynchronized; use OCP\EventDispatcher\Event; @@ -34,7 +33,6 @@ public function handle(Event $event): void { return; } - /** @var Message $message */ foreach ($event->getMessages() as $message) { $uri = $this->urlGenerator->linkToOCSRouteAbsolute('mail.messageApi.get', ['id' => $message->getId()]); $this->eventDispatcher->dispatchTyped(new NewMessageReceivedEvent($uri)); diff --git a/lib/Migration/FixBackgroundJobs.php b/lib/Migration/FixBackgroundJobs.php index 2ee5d3de10..46cb35bd15 100644 --- a/lib/Migration/FixBackgroundJobs.php +++ b/lib/Migration/FixBackgroundJobs.php @@ -13,7 +13,6 @@ use OCA\Mail\BackgroundJob\RepairSyncJob; use OCA\Mail\BackgroundJob\SyncJob; use OCA\Mail\BackgroundJob\TrainImportanceClassifierJob; -use OCA\Mail\Db\MailAccount; use OCA\Mail\Db\MailAccountMapper; use OCP\BackgroundJob\IJobList; use OCP\Migration\IOutput; @@ -38,7 +37,6 @@ public function getName(): string { * @return void */ public function run(IOutput $output) { - /** @var MailAccount[] $accounts */ $accounts = $this->mapper->getAllAccounts(); $output->startProgress(count($accounts)); diff --git a/lib/Migration/Version3001Date20230307113544.php b/lib/Migration/Version3001Date20230307113544.php index 9c880653b4..34d5bb426c 100644 --- a/lib/Migration/Version3001Date20230307113544.php +++ b/lib/Migration/Version3001Date20230307113544.php @@ -16,7 +16,6 @@ class Version3001Date20230307113544 extends SimpleMigrationStep { public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $accountsTable = $schema->getTable('mail_accounts'); diff --git a/lib/Migration/Version3300Date20230706140531.php b/lib/Migration/Version3300Date20230706140531.php index 0c99ca62f7..e006be5c27 100644 --- a/lib/Migration/Version3300Date20230706140531.php +++ b/lib/Migration/Version3300Date20230706140531.php @@ -23,7 +23,6 @@ class Version3300Date20230706140531 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $accountsTable = $schema->getTable('mail_accounts'); diff --git a/lib/Migration/Version3300Date20230801124717.php b/lib/Migration/Version3300Date20230801124717.php index 74472326d8..736fe09988 100644 --- a/lib/Migration/Version3300Date20230801124717.php +++ b/lib/Migration/Version3300Date20230801124717.php @@ -24,7 +24,6 @@ class Version3300Date20230801124717 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $accountsTable = $schema->getTable('mail_accounts'); diff --git a/lib/Migration/Version3400Date20230807300513.php b/lib/Migration/Version3400Date20230807300513.php index 68215cedc4..f6bb54a8d6 100644 --- a/lib/Migration/Version3400Date20230807300513.php +++ b/lib/Migration/Version3400Date20230807300513.php @@ -24,7 +24,6 @@ class Version3400Date20230807300513 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $accountsTable = $schema->getTable('mail_accounts'); diff --git a/lib/Migration/Version3400Date20230814160451.php b/lib/Migration/Version3400Date20230814160451.php index cb40367bf0..da22948798 100644 --- a/lib/Migration/Version3400Date20230814160451.php +++ b/lib/Migration/Version3400Date20230814160451.php @@ -23,7 +23,6 @@ class Version3400Date20230814160451 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $accountsTable = $schema->getTable('mail_accounts'); diff --git a/lib/Migration/Version3400Date20230818160236.php b/lib/Migration/Version3400Date20230818160236.php index 4c1adb39db..7fc333271d 100644 --- a/lib/Migration/Version3400Date20230818160236.php +++ b/lib/Migration/Version3400Date20230818160236.php @@ -24,7 +24,6 @@ class Version3400Date20230818160236 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $snoozeTable = $schema->getTable('mail_messages_snoozed'); diff --git a/lib/Migration/Version3400Date20230819161945.php b/lib/Migration/Version3400Date20230819161945.php index afa434adeb..157a427d45 100644 --- a/lib/Migration/Version3400Date20230819161945.php +++ b/lib/Migration/Version3400Date20230819161945.php @@ -23,7 +23,6 @@ class Version3400Date20230819161945 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $messagesRetentionTable = $schema->getTable('mail_messages_retention'); diff --git a/lib/Migration/Version3400Date20230823153943.php b/lib/Migration/Version3400Date20230823153943.php index 14cddb4172..4bee41551c 100644 --- a/lib/Migration/Version3400Date20230823153943.php +++ b/lib/Migration/Version3400Date20230823153943.php @@ -23,7 +23,6 @@ class Version3400Date20230823153943 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $messagesSnoozedTable = $schema->getTable('mail_messages_snoozed'); diff --git a/lib/Migration/Version3400Date20230907103114.php b/lib/Migration/Version3400Date20230907103114.php index 6d5f8ff616..a85dbb857d 100644 --- a/lib/Migration/Version3400Date20230907103114.php +++ b/lib/Migration/Version3400Date20230907103114.php @@ -33,7 +33,6 @@ public function preSchemaChange(IOutput $output, Closure $schemaClosure, array $ } public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $retentionTable = $schema->getTable('mail_messages_retention'); diff --git a/lib/Migration/Version3500Date20231009102414.php b/lib/Migration/Version3500Date20231009102414.php index 0bd6e78975..ea22ba5838 100644 --- a/lib/Migration/Version3500Date20231009102414.php +++ b/lib/Migration/Version3500Date20231009102414.php @@ -24,7 +24,6 @@ class Version3500Date20231009102414 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $mailAccountsTable = $schema->getTable('mail_accounts'); diff --git a/lib/Migration/Version3500Date20231114180656.php b/lib/Migration/Version3500Date20231114180656.php index 29f2a29577..5b431669f0 100644 --- a/lib/Migration/Version3500Date20231114180656.php +++ b/lib/Migration/Version3500Date20231114180656.php @@ -23,7 +23,6 @@ class Version3500Date20231114180656 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $accountsTable = $schema->getTable('mail_accounts'); diff --git a/lib/Migration/Version3500Date20231115182612.php b/lib/Migration/Version3500Date20231115182612.php index 728ed7d76d..7cce1df1fd 100644 --- a/lib/Migration/Version3500Date20231115182612.php +++ b/lib/Migration/Version3500Date20231115182612.php @@ -30,7 +30,6 @@ public function __construct( * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $mailboxesTable = $schema->getTable('mail_mailboxes'); diff --git a/lib/Migration/Version3500Date20231115184458.php b/lib/Migration/Version3500Date20231115184458.php index 036fd13603..336e68a883 100644 --- a/lib/Migration/Version3500Date20231115184458.php +++ b/lib/Migration/Version3500Date20231115184458.php @@ -23,7 +23,6 @@ class Version3500Date20231115184458 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $mailboxesTable = $schema->getTable('mail_mailboxes'); diff --git a/lib/Migration/Version3600Date20240205180726.php b/lib/Migration/Version3600Date20240205180726.php index bf09feeebf..d350bfc6e2 100644 --- a/lib/Migration/Version3600Date20240205180726.php +++ b/lib/Migration/Version3600Date20240205180726.php @@ -23,7 +23,6 @@ class Version3600Date20240205180726 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $mailboxesTable = $schema->getTable('mail_messages'); diff --git a/lib/Migration/Version3600Date20240220134813.php b/lib/Migration/Version3600Date20240220134813.php index b70ef68a4a..9ffd3816ee 100644 --- a/lib/Migration/Version3600Date20240220134813.php +++ b/lib/Migration/Version3600Date20240220134813.php @@ -24,7 +24,6 @@ class Version3600Date20240220134813 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $localMessagesTable = $schema->getTable('mail_local_messages'); diff --git a/lib/Migration/Version3700Date20240430115406.php b/lib/Migration/Version3700Date20240430115406.php index 24eefd77ca..5ef0d2a530 100644 --- a/lib/Migration/Version3700Date20240430115406.php +++ b/lib/Migration/Version3700Date20240430115406.php @@ -32,7 +32,6 @@ public function __construct( * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $localMessagesTable = $schema->getTable('mail_local_messages'); diff --git a/lib/Migration/Version3700Date20240506161400.php b/lib/Migration/Version3700Date20240506161400.php index da4efcc399..4960e092a4 100644 --- a/lib/Migration/Version3700Date20240506161400.php +++ b/lib/Migration/Version3700Date20240506161400.php @@ -24,7 +24,6 @@ class Version3700Date20240506161400 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $localMessagesTable = $schema->getTable('mail_local_messages'); diff --git a/lib/Migration/Version3800Date20240628163133.php b/lib/Migration/Version3800Date20240628163133.php index a76fc0cbc4..37cb7fa2fd 100644 --- a/lib/Migration/Version3800Date20240628163133.php +++ b/lib/Migration/Version3800Date20240628163133.php @@ -24,7 +24,6 @@ public function __construct( } public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $accounts = $schema->getTable('mail_accounts'); diff --git a/lib/Migration/Version4000Date20240716172702.php b/lib/Migration/Version4000Date20240716172702.php index 914c9fe52a..d3bae214e9 100644 --- a/lib/Migration/Version4000Date20240716172702.php +++ b/lib/Migration/Version4000Date20240716172702.php @@ -23,7 +23,6 @@ class Version4000Date20240716172702 extends SimpleMigrationStep { * @return ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); if (!$schema->hasTable('mail_internal_address')) { diff --git a/lib/Migration/Version4001Date20241009140707.php b/lib/Migration/Version4001Date20241009140707.php index 155d6310f2..06ac021b97 100644 --- a/lib/Migration/Version4001Date20241009140707.php +++ b/lib/Migration/Version4001Date20241009140707.php @@ -26,7 +26,6 @@ class Version4001Date20241009140707 extends SimpleMigrationStep { */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); $messagesTable = $schema->getTable('mail_messages'); diff --git a/lib/Migration/Version4100Date20241021091352.php b/lib/Migration/Version4100Date20241021091352.php index f1c8339a32..ee28722bc6 100644 --- a/lib/Migration/Version4100Date20241021091352.php +++ b/lib/Migration/Version4100Date20241021091352.php @@ -22,7 +22,6 @@ class Version4100Date20241021091352 extends SimpleMigrationStep { * @return null|ISchemaWrapper */ public function changeSchema(IOutput $output, Closure $schemaClosure, array $options): ?ISchemaWrapper { - /** @var ISchemaWrapper $schema */ $schema = $schemaClosure(); if ($schema->hasTable('mail_classifiers')) { diff --git a/lib/Service/HtmlPurify/TransformURLScheme.php b/lib/Service/HtmlPurify/TransformURLScheme.php index c3acccfab6..8c46bd9068 100644 --- a/lib/Service/HtmlPurify/TransformURLScheme.php +++ b/lib/Service/HtmlPurify/TransformURLScheme.php @@ -55,7 +55,6 @@ public function __construct(array $messageParameters, * @return bool */ public function filter(&$uri, $config, $context) { - /** @var \HTMLPurifier_Context $context */ if ($uri->scheme === null) { $uri->scheme = 'https';