diff options
author | Joas Schilling <coding@schilljs.com> | 2021-08-26 15:14:05 +0300 |
---|---|---|
committer | Gary Kim <gary@garykim.dev> | 2021-09-20 21:30:30 +0300 |
commit | a3cd8312a28942cda4260892f442834d41d66e54 (patch) | |
tree | 2e50d5b632898d5ea12086b214f9df6a0367bc4f /lib/Federation | |
parent | 9f3695d748d163f2de5ea5ef394b8d7a0caf7a6a (diff) |
Strict
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/Federation')
-rw-r--r-- | lib/Federation/Notifications.php | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/lib/Federation/Notifications.php b/lib/Federation/Notifications.php index f88d902ff..9df734582 100644 --- a/lib/Federation/Notifications.php +++ b/lib/Federation/Notifications.php @@ -29,7 +29,6 @@ use OCA\FederatedFileSharing\AddressHandler; use OCA\Talk\AppInfo\Application; use OCA\Talk\BackgroundJob\RetryJob; use OCA\Talk\Exceptions\RoomHasNoModeratorException; -use OCA\Talk\MatterbridgeManager; use OCA\Talk\Model\Attendee; use OCA\Talk\Model\AttendeeMapper; use OCA\Talk\Participant; @@ -64,9 +63,6 @@ class Notifications { /** @var AttendeeMapper */ private $attendeeMapper; - /** @var MatterbridgeManager */ - private $matterbridgeManager; - public function __construct( ICloudFederationFactory $cloudFederationFactory, AddressHandler $addressHandler, @@ -74,8 +70,7 @@ class Notifications { ICloudFederationProviderManager $federationProviderManager, IJobList $jobList, IUserManager $userManager, - AttendeeMapper $attendeeMapper, - MatterbridgeManager $matterbridgeManager + AttendeeMapper $attendeeMapper ) { $this->cloudFederationFactory = $cloudFederationFactory; $this->addressHandler = $addressHandler; @@ -84,7 +79,6 @@ class Notifications { $this->jobList = $jobList; $this->userManager = $userManager; $this->attendeeMapper = $attendeeMapper; - $this->matterbridgeManager = $matterbridgeManager; } /** @@ -217,7 +211,7 @@ class Notifications { return true; } - public function sendRemoteUnShare(string $remote, string $id, string $token) { + public function sendRemoteUnShare(string $remote, string $id, string $token): void { $remote = $this->prepareRemoteUrl($remote); $notification = $this->cloudFederationFactory->getCloudFederationNotification(); @@ -234,7 +228,7 @@ class Notifications { $this->sendUpdateToRemote($remote, $notification); } - public function sendUpdateDataToRemote(string $remote, array $data = [], int $try = 0) { + public function sendUpdateDataToRemote(string $remote, array $data = [], int $try = 0): void { $notification = $this->cloudFederationFactory->getCloudFederationNotification(); $notification->setMessage( $data['notificationType'], @@ -245,7 +239,7 @@ class Notifications { $this->sendUpdateToRemote($remote, $notification, $try); } - public function sendUpdateToRemote(string $remote, ICloudFederationNotification $notification, int $try = 0) { + public function sendUpdateToRemote(string $remote, ICloudFederationNotification $notification, int $try = 0): void { $response = $this->federationProviderManager->sendNotification($remote, $notification); if (!is_array($response)) { $this->jobList->add(RetryJob::class, @@ -260,7 +254,7 @@ class Notifications { private function prepareRemoteUrl(string $remote): string { if ($this->addressHandler->urlContainProtocol($remote)) { - return "https://" . $remote; + return 'https://' . $remote; } return $remote; } |