Skip to content

Commit 2272542

Browse files
authored
Merge pull request #169 from laravel-notification-channels/analysis-bQ4w3w
Apply fixes from StyleCI
2 parents b7171bc + cc788ec commit 2272542

11 files changed

+55
-54
lines changed

config/webpush.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737

3838
/**
3939
* Google Cloud Messaging.
40+
*
4041
* @deprecated
4142
*/
4243
'gcm' => [

src/Events/NotificationFailed.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ class NotificationFailed
2626
/**
2727
* Create a new event instance.
2828
*
29-
* @param \Minishlink\WebPush\MessageSentReport $report
30-
* @param \NotificationChannels\WebPush\PushSubscription $subscription
31-
* @param \NotificationChannels\WebPush\WebPushMessage $message
29+
* @param \Minishlink\WebPush\MessageSentReport $report
30+
* @param \NotificationChannels\WebPush\PushSubscription $subscription
31+
* @param \NotificationChannels\WebPush\WebPushMessage $message
3232
* @return void
3333
*/
3434
public function __construct($report, $subscription, $message)

src/Events/NotificationSent.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ class NotificationSent
2626
/**
2727
* Create a new event instance.
2828
*
29-
* @param \Minishlink\WebPush\MessageSentReport $report
30-
* @param \NotificationChannels\WebPush\PushSubscription $subscription
31-
* @param \NotificationChannels\WebPush\WebPushMessage $message
29+
* @param \Minishlink\WebPush\MessageSentReport $report
30+
* @param \NotificationChannels\WebPush\PushSubscription $subscription
31+
* @param \NotificationChannels\WebPush\WebPushMessage $message
3232
* @return void
3333
*/
3434
public function __construct($report, $subscription, $message)

src/HasPushSubscriptions.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ public function pushSubscriptions()
1717
/**
1818
* Update (or create) subscription.
1919
*
20-
* @param string $endpoint
21-
* @param string|null $key
22-
* @param string|null $token
23-
* @param string|null $contentEncoding
20+
* @param string $endpoint
21+
* @param string|null $key
22+
* @param string|null $token
23+
* @param string|null $contentEncoding
2424
* @return \NotificationChannels\WebPush\PushSubscription
2525
*/
2626
public function updatePushSubscription($endpoint, $key = null, $token = null, $contentEncoding = null)
@@ -51,7 +51,7 @@ public function updatePushSubscription($endpoint, $key = null, $token = null, $c
5151
/**
5252
* Determine if the model owns the given subscription.
5353
*
54-
* @param \NotificationChannels\WebPush\PushSubscription $subscription
54+
* @param \NotificationChannels\WebPush\PushSubscription $subscription
5555
* @return bool
5656
*/
5757
public function ownsPushSubscription($subscription)
@@ -63,7 +63,7 @@ public function ownsPushSubscription($subscription)
6363
/**
6464
* Delete subscription by endpoint.
6565
*
66-
* @param string $endpoint
66+
* @param string $endpoint
6767
* @return void
6868
*/
6969
public function deletePushSubscription($endpoint)

src/PushSubscription.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ class PushSubscription extends Model
2828
/**
2929
* Create a new model instance.
3030
*
31-
* @param array $attributes
31+
* @param array $attributes
3232
* @return void
3333
*/
3434
public function __construct(array $attributes = [])
@@ -57,7 +57,7 @@ public function subscribable()
5757
/**
5858
* Find a subscription by the given endpint.
5959
*
60-
* @param string $endpoint
60+
* @param string $endpoint
6161
* @return static|null
6262
*/
6363
public static function findByEndpoint($endpoint)

src/ReportHandler.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ class ReportHandler implements ReportHandlerInterface
1616
/**
1717
* Create a new report handler.
1818
*
19-
* @param \Illuminate\Contracts\Events\Dispatcher $events
19+
* @param \Illuminate\Contracts\Events\Dispatcher $events
2020
* @return void
2121
*/
2222
public function __construct(Dispatcher $events)
@@ -27,9 +27,9 @@ public function __construct(Dispatcher $events)
2727
/**
2828
* Handle a message sent report.
2929
*
30-
* @param \Minishlink\WebPush\MessageSentReport $report
31-
* @param \NotificationChannels\WebPush\PushSubscription $subscription
32-
* @param \NotificationChannels\WebPush\WebPushMessage $message
30+
* @param \Minishlink\WebPush\MessageSentReport $report
31+
* @param \NotificationChannels\WebPush\PushSubscription $subscription
32+
* @param \NotificationChannels\WebPush\WebPushMessage $message
3333
* @return void
3434
*/
3535
public function handleReport($report, $subscription, $message)

src/ReportHandlerInterface.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ interface ReportHandlerInterface
77
/**
88
* Handle a message sent report.
99
*
10-
* @param \Minishlink\WebPush\MessageSentReport $report
11-
* @param \NotificationChannels\WebPush\PushSubscription $subscription
12-
* @param \NotificationChannels\WebPush\WebPushMessage $message
10+
* @param \Minishlink\WebPush\MessageSentReport $report
11+
* @param \NotificationChannels\WebPush\PushSubscription $subscription
12+
* @param \NotificationChannels\WebPush\WebPushMessage $message
1313
* @return void
1414
*/
1515
public function handleReport($report, $subscription, $message);

src/VapidKeysGenerateCommand.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public function handle()
4949
/**
5050
* Set the keys in the environment file.
5151
*
52-
* @param array $keys
52+
* @param array $keys
5353
* @return bool
5454
*/
5555
protected function setKeysInEnvironmentFile($keys)
@@ -68,7 +68,7 @@ protected function setKeysInEnvironmentFile($keys)
6868
/**
6969
* Write a new environment file with the given keys.
7070
*
71-
* @param array $keys
71+
* @param array $keys
7272
* @return void
7373
*/
7474
protected function writeNewEnvironmentFileWith($keys)
@@ -101,7 +101,7 @@ protected function writeNewEnvironmentFileWith($keys)
101101
/**
102102
* Get a regex pattern that will match env $keyName with any key.
103103
*
104-
* @param string $keyName
104+
* @param string $keyName
105105
* @return string
106106
*/
107107
protected function keyReplacementPattern($keyName)

src/WebPushChannel.php

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ class WebPushChannel
1919
protected $reportHandler;
2020

2121
/**
22-
* @param \Minishlink\WebPush\WebPush $webPush
23-
* @param \NotificationChannels\WebPush\ReportHandlerInterface $webPush
22+
* @param \Minishlink\WebPush\WebPush $webPush
23+
* @param \NotificationChannels\WebPush\ReportHandlerInterface $webPush
2424
* @return void
2525
*/
2626
public function __construct(WebPush $webPush, ReportHandlerInterface $reportHandler)
@@ -32,8 +32,8 @@ public function __construct(WebPush $webPush, ReportHandlerInterface $reportHand
3232
/**
3333
* Send the given notification.
3434
*
35-
* @param mixed $notifiable
36-
* @param \Illuminate\Notifications\Notification $notification
35+
* @param mixed $notifiable
36+
* @param \Illuminate\Notifications\Notification $notification
3737
* @return void
3838
*/
3939
public function send($notifiable, Notification $notification)
@@ -68,9 +68,9 @@ public function send($notifiable, Notification $notification)
6868
/**
6969
* Handle the reports.
7070
*
71-
* @param \Generator $reports
72-
* @param \Illuminate\Database\Eloquent\Collection $subscriptions
73-
* @param \NotificationChannels\WebPush\WebPushMessage $message
71+
* @param \Generator $reports
72+
* @param \Illuminate\Database\Eloquent\Collection $subscriptions
73+
* @param \NotificationChannels\WebPush\WebPushMessage $message
7474
* @return void
7575
*/
7676
protected function handleReports($reports, $subscriptions, $message)
@@ -84,8 +84,8 @@ protected function handleReports($reports, $subscriptions, $message)
8484
}
8585

8686
/**
87-
* @param \Illuminate\Database\Eloquent\Collection $subscriptions
88-
* @param \Minishlink\WebPush\MessageSentReport $report
87+
* @param \Illuminate\Database\Eloquent\Collection $subscriptions
88+
* @param \Minishlink\WebPush\MessageSentReport $report
8989
* @return void
9090
*/
9191
protected function findSubscription($subscriptions, $report)

src/WebPushMessage.php

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ class WebPushMessage
8282
/**
8383
* Set the notification title.
8484
*
85-
* @param string $value
85+
* @param string $value
8686
* @return $this
8787
*/
8888
public function title($value)
@@ -95,9 +95,9 @@ public function title($value)
9595
/**
9696
* Add a notification action.
9797
*
98-
* @param string $title
99-
* @param string $action
100-
* @param string $icon
98+
* @param string $title
99+
* @param string $action
100+
* @param string $icon
101101
* @return $this
102102
*/
103103
public function action($title, $action, $icon = null)
@@ -110,7 +110,7 @@ public function action($title, $action, $icon = null)
110110
/**
111111
* Set the notification badge.
112112
*
113-
* @param string $value
113+
* @param string $value
114114
* @return $this
115115
*/
116116
public function badge($value)
@@ -123,7 +123,7 @@ public function badge($value)
123123
/**
124124
* Set the notification body.
125125
*
126-
* @param string $value
126+
* @param string $value
127127
* @return $this
128128
*/
129129
public function body($value)
@@ -136,7 +136,7 @@ public function body($value)
136136
/**
137137
* Set the notification direction.
138138
*
139-
* @param string $value
139+
* @param string $value
140140
* @return $this
141141
*/
142142
public function dir($value)
@@ -149,7 +149,7 @@ public function dir($value)
149149
/**
150150
* Set the notification icon url.
151151
*
152-
* @param string $value
152+
* @param string $value
153153
* @return $this
154154
*/
155155
public function icon($value)
@@ -162,7 +162,7 @@ public function icon($value)
162162
/**
163163
* Set the notification image url.
164164
*
165-
* @param string $value
165+
* @param string $value
166166
* @return $this
167167
*/
168168
public function image($value)
@@ -175,7 +175,7 @@ public function image($value)
175175
/**
176176
* Set the notification language.
177177
*
178-
* @param string $value
178+
* @param string $value
179179
* @return $this
180180
*/
181181
public function lang($value)
@@ -186,7 +186,7 @@ public function lang($value)
186186
}
187187

188188
/**
189-
* @param bool $value
189+
* @param bool $value
190190
* @return $this
191191
*/
192192
public function renotify($value = true)
@@ -197,7 +197,7 @@ public function renotify($value = true)
197197
}
198198

199199
/**
200-
* @param bool $value
200+
* @param bool $value
201201
* @return $this
202202
*/
203203
public function requireInteraction($value = true)
@@ -210,7 +210,7 @@ public function requireInteraction($value = true)
210210
/**
211211
* Set the notification tag.
212212
*
213-
* @param string $value
213+
* @param string $value
214214
* @return $this
215215
*/
216216
public function tag($value)
@@ -223,7 +223,7 @@ public function tag($value)
223223
/**
224224
* Set the notification vibration pattern.
225225
*
226-
* @param array $value
226+
* @param array $value
227227
* @return $this
228228
*/
229229
public function vibrate($value)
@@ -236,7 +236,7 @@ public function vibrate($value)
236236
/**
237237
* Set the notification arbitrary data.
238238
*
239-
* @param mixed $value
239+
* @param mixed $value
240240
* @return $this
241241
*/
242242
public function data($value)
@@ -251,7 +251,7 @@ public function data($value)
251251
*
252252
* @link https://github.com/web-push-libs/web-push-php#notifications-and-default-options
253253
*
254-
* @param array $value
254+
* @param array $value
255255
* @return $this
256256
*/
257257
public function options(array $value)

tests/TestCase.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ protected function setUp(): void
2424
/**
2525
* Set up the environment.
2626
*
27-
* @param \Illuminate\Foundation\Application $app
27+
* @param \Illuminate\Foundation\Application $app
2828
* @return void
2929
*/
3030
protected function getEnvironmentSetUp($app)
@@ -33,7 +33,7 @@ protected function getEnvironmentSetUp($app)
3333
}
3434

3535
/**
36-
* @param \Illuminate\Foundation\Application $app
36+
* @param \Illuminate\Foundation\Application $app
3737
* @return array
3838
*/
3939
protected function getPackageProviders($app)
@@ -70,8 +70,8 @@ public function createUser(array $attributes)
7070
}
7171

7272
/**
73-
* @param \NotificationChannels\WebPush\Test\User $user
74-
* @param string $endpoint
73+
* @param \NotificationChannels\WebPush\Test\User $user
74+
* @param string $endpoint
7575
* @return \NotificationChannels\WebPush\PushSubscription
7676
*/
7777
public function createSubscription($user, $endpoint = 'endpoint')
@@ -85,7 +85,7 @@ public function createSubscription($user, $endpoint = 'endpoint')
8585
}
8686

8787
/**
88-
* @param string $expectedText
88+
* @param string $expectedText
8989
* @return void
9090
*/
9191
protected function seeInConsoleOutput($expectedText)

0 commit comments

Comments
 (0)