Skip to content

Commit

Permalink
fix: style (#88)
Browse files Browse the repository at this point in the history
  • Loading branch information
atymic authored Sep 10, 2021
1 parent 04d074b commit f927556
Show file tree
Hide file tree
Showing 10 changed files with 29 additions and 31 deletions.
2 changes: 1 addition & 1 deletion src/Events/NotificationInterrupted.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class NotificationInterrupted
/**
* Create a new event instance.
*
* @param \Thomasjohnkane\Snooze\Models\ScheduledNotification $scheduledNotification
* @param \Thomasjohnkane\Snooze\Models\ScheduledNotification $scheduledNotification
* @return void
*/
public function __construct(ScheduledNotification $scheduledNotification)
Expand Down
2 changes: 1 addition & 1 deletion src/Events/NotificationSent.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class NotificationSent
/**
* Create a new event instance.
*
* @param \Thomasjohnkane\Snooze\Models\ScheduledNotification $scheduledNotification
* @param \Thomasjohnkane\Snooze\Models\ScheduledNotification $scheduledNotification
* @return void
*/
public function __construct(ScheduledNotification $scheduledNotification)
Expand Down
16 changes: 7 additions & 9 deletions src/Models/ScheduledNotification.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,8 @@ public function send(): void
}

/**
* @param object|null $notification
*
* @param object|null $notifiable
*
* @param object|null $notification
* @param object|null $notifiable
* @return bool
*/
public function shouldInterrupt(?object $notification = null, ?object $notifiable = null): bool
Expand All @@ -106,6 +104,7 @@ public function shouldInterrupt(?object $notification = null, ?object $notifiabl

/**
* @return void
*
* @throws NotificationAlreadySentException
*/
public function cancel(): void
Expand All @@ -119,10 +118,10 @@ public function cancel(): void
}

/**
* @param \DateTimeInterface|string $sendAt
* @param bool $force
*
* @param \DateTimeInterface|string $sendAt
* @param bool $force
* @return self
*
* @throws NotificationAlreadySentException
* @throws NotificationCancelledException
*/
Expand Down Expand Up @@ -152,8 +151,7 @@ public function reschedule($sendAt, $force = false): self
}

/**
* @param \DateTimeInterface|string $sendAt
*
* @param \DateTimeInterface|string $sendAt
* @return self
*/
public function scheduleAgainAt($sendAt): self
Expand Down
17 changes: 8 additions & 9 deletions src/ScheduledNotification.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ public function __construct(ScheduledNotificationModel $scheduleNotificationMode
}

/**
* @param object $notifiable
* @param Notification $notification
* @param DateTimeInterface $sendAt
*
* @param object $notifiable
* @param Notification $notification
* @param DateTimeInterface $sendAt
* @return self
*
* @throws SchedulingFailedException
*/
public static function create(
Expand Down Expand Up @@ -157,10 +157,10 @@ public static function cancelAnonymousNotificationsByChannel(string $channel, st
}

/**
* @param DateTimeInterface|string $sendAt
* @param bool $force
*
* @param DateTimeInterface|string $sendAt
* @param bool $force
* @return self
*
* @throws NotificationAlreadySentException
* @throws NotificationCancelledException
*/
Expand All @@ -170,8 +170,7 @@ public function reschedule($sendAt, $force = false): self
}

/**
* @param DateTimeInterface|string $sendAt
*
* @param DateTimeInterface|string $sendAt
* @return self
*/
public function scheduleAgainAt($sendAt): self
Expand Down
6 changes: 3 additions & 3 deletions src/Traits/SnoozeNotifiable.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@
trait SnoozeNotifiable
{
/**
* @param Notification $notification
* @param DateTimeInterface $sendAt
*
* @param Notification $notification
* @param DateTimeInterface $sendAt
* @return ScheduledNotification
*
* @throws SchedulingFailedException
*/
public function notifyAt($notification, DateTimeInterface $sendAt): ScheduledNotification
Expand Down
4 changes: 2 additions & 2 deletions tests/Notifications/TestInterruptableNotification.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class TestInterruptableNotification extends Notification implements ShouldQueue
public $newUser;

/**
* @param User $newUser
* @param User $newUser
*/
public function __construct(User $newUser)
{
Expand All @@ -26,7 +26,7 @@ public function __construct(User $newUser)
/**
* Get the notification's channels.
*
* @param mixed $notifiable
* @param mixed $notifiable
* @return array|string
*/
public function via($notifiable)
Expand Down
4 changes: 2 additions & 2 deletions tests/Notifications/TestNotification.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class TestNotification extends Notification implements ShouldQueue
public $newUser;

/**
* @param User $newUser
* @param User $newUser
*/
public function __construct(User $newUser)
{
Expand All @@ -26,7 +26,7 @@ public function __construct(User $newUser)
/**
* Get the notification's channels.
*
* @param mixed $notifiable
* @param mixed $notifiable
* @return array|string
*/
public function via($notifiable)
Expand Down
4 changes: 2 additions & 2 deletions tests/Notifications/TestNotificationTwo.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class TestNotificationTwo extends Notification implements ShouldQueue
public $newUser;

/**
* @param User $newUser
* @param User $newUser
*/
public function __construct(User $newUser)
{
Expand All @@ -26,7 +26,7 @@ public function __construct(User $newUser)
/**
* Get the notification's channels.
*
* @param mixed $notifiable
* @param mixed $notifiable
* @return array|string
*/
public function via($notifiable)
Expand Down
1 change: 1 addition & 0 deletions tests/ScheduledNotificationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ class ScheduledNotificationTest extends TestCase
{
/**
* Check that the multiply method returns correct result.
*
* @return void
*/
public function testItRunsMigrations()
Expand Down
4 changes: 2 additions & 2 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ protected function initializeDirectory($directory)
}

/**
* @param \Illuminate\Foundation\Application $app
* @param \Illuminate\Foundation\Application $app
*/
protected function getEnvironmentSetUp($app)
{
Expand All @@ -64,7 +64,7 @@ protected function getEnvironmentSetUp($app)
}

/**
* @param \Illuminate\Foundation\Application $app
* @param \Illuminate\Foundation\Application $app
*/
protected function setUpDatabase($app)
{
Expand Down

0 comments on commit f927556

Please sign in to comment.