Skip to content

Commit

Permalink
Dropped null sms related messages
Browse files Browse the repository at this point in the history
  • Loading branch information
ViniTou committed Jul 5, 2024
1 parent d86357d commit ba5f828
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 27 deletions.
10 changes: 1 addition & 9 deletions src/contracts/Notification/UserInvitation.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,12 @@
use Ibexa\Contracts\User\Invitation\Invitation;
use Symfony\Bridge\Twig\Mime\NotificationEmail;
use Symfony\Component\Notifier\Message\EmailMessage;
use Symfony\Component\Notifier\Message\SmsMessage;
use Symfony\Component\Notifier\Notification\EmailNotificationInterface;
use Symfony\Component\Notifier\Notification\Notification;
use Symfony\Component\Notifier\Notification\SmsNotificationInterface;
use Symfony\Component\Notifier\Recipient\EmailRecipientInterface;
use Symfony\Component\Notifier\Recipient\SmsRecipientInterface;
use Twig\Environment;

final class UserInvitation extends Notification implements EmailNotificationInterface, SmsNotificationInterface
final class UserInvitation extends Notification implements EmailNotificationInterface
{
private Invitation $invitation;

Expand Down Expand Up @@ -72,9 +69,4 @@ public function asEmailMessage(EmailRecipientInterface $recipient, string $trans

return new EmailMessage($email);
}

public function asSmsMessage(SmsRecipientInterface $recipient, string $transport = null): ?SmsMessage
{
return null;
}
}
10 changes: 1 addition & 9 deletions src/contracts/Notification/UserPasswordReset.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,12 @@
use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface;
use Symfony\Bridge\Twig\Mime\NotificationEmail;
use Symfony\Component\Notifier\Message\EmailMessage;
use Symfony\Component\Notifier\Message\SmsMessage;
use Symfony\Component\Notifier\Notification\EmailNotificationInterface;
use Symfony\Component\Notifier\Notification\Notification;
use Symfony\Component\Notifier\Notification\SmsNotificationInterface;
use Symfony\Component\Notifier\Recipient\EmailRecipientInterface;
use Symfony\Component\Notifier\Recipient\SmsRecipientInterface;
use Twig\Environment;

final class UserPasswordReset extends Notification implements EmailNotificationInterface, SmsNotificationInterface, UserAwareNotificationInterface
final class UserPasswordReset extends Notification implements EmailNotificationInterface, UserAwareNotificationInterface
{
private User $user;

Expand Down Expand Up @@ -66,11 +63,6 @@ public function asEmailMessage(EmailRecipientInterface $recipient, string $trans
return new EmailMessage($email);
}

public function asSmsMessage(SmsRecipientInterface $recipient, string $transport = null): ?SmsMessage
{
return null;
}

public function getUser(): User
{
return $this->user;
Expand Down
10 changes: 1 addition & 9 deletions src/contracts/Notification/UserRegister.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,11 @@

use Ibexa\Contracts\Core\Repository\Values\User\User;
use Symfony\Component\Notifier\Message\EmailMessage;
use Symfony\Component\Notifier\Message\SmsMessage;
use Symfony\Component\Notifier\Notification\EmailNotificationInterface;
use Symfony\Component\Notifier\Notification\Notification;
use Symfony\Component\Notifier\Notification\SmsNotificationInterface;
use Symfony\Component\Notifier\Recipient\EmailRecipientInterface;
use Symfony\Component\Notifier\Recipient\SmsRecipientInterface;

final class UserRegister extends Notification implements EmailNotificationInterface, SmsNotificationInterface, UserAwareNotificationInterface
final class UserRegister extends Notification implements EmailNotificationInterface, UserAwareNotificationInterface
{
private User $user;

Expand All @@ -33,11 +30,6 @@ public function asEmailMessage(EmailRecipientInterface $recipient, string $trans
return null;
}

public function asSmsMessage(SmsRecipientInterface $recipient, string $transport = null): ?SmsMessage
{
return null;
}

public function getUser(): User
{
return $this->user;
Expand Down

0 comments on commit ba5f828

Please sign in to comment.