Issues (2)

src/SmspohServiceProvider.php (1 issue)

1
<?php
2
3
namespace NotificationChannels\Smspoh;
4
5
use GuzzleHttp\Client as HttpClient;
6
use Illuminate\Notifications\ChannelManager;
7
use Illuminate\Support\Facades\Notification;
8
use Illuminate\Support\ServiceProvider;
9
10
class SmspohServiceProvider extends ServiceProvider
11
{
12
    /**
13
     * Bootstrap the application services.
14
     */
15 10
    public function boot()
16
    {
17 10
    }
18
19
    /**
20
     * Register the application services.
21
     */
22 10
    public function register()
23
    {
24
        $this->app->singleton(SmspohApi::class, static function ($app) {
0 ignored issues
show
The parameter $app is not used and could be removed. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-unused  annotation

24
        $this->app->singleton(SmspohApi::class, static function (/** @scrutinizer ignore-unused */ $app) {

This check looks for parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
25
            return new SmspohApi(config('services.smspoh.token'), new HttpClient());
26 10
        });
27
28
        Notification::resolved(function (ChannelManager $service) {
29
            $service->extend('smspoh', function ($app) {
30
                return new SmspohChannel($app[SmspohApi::class], $this->app['config']['services.smspoh.sender']);
31
            });
32 10
        });
33 10
    }
34
}
35