GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Code Duplication    Length = 43-47 lines in 3 locations

app/Notifications/AddedToServer.php 1 location

@@ 32-74 (lines=43) @@
29
use Illuminate\Contracts\Queue\ShouldQueue;
30
use Illuminate\Notifications\Messages\MailMessage;
31
32
class AddedToServer extends Notification implements ShouldQueue
33
{
34
    use Queueable;
35
36
    /**
37
     * @var object
38
     */
39
    public $server;
40
41
    /**
42
     * Create a new notification instance.
43
     *
44
     * @param  array  $server
45
     * @return void
46
     */
47
    public function __construct(array $server)
48
    {
49
        $this->server = (object) $server;
50
    }
51
52
    /**
53
     * Get the notification's delivery channels.
54
     *
55
     * @param  mixed  $notifiable
56
     * @return array
57
     */
58
    public function via($notifiable)
59
    {
60
        return ['mail'];
61
    }
62
63
    /**
64
     * Get the mail representation of the notification.
65
     *
66
     * @param  mixed  $notifiable
67
     * @return \Illuminate\Notifications\Messages\MailMessage
68
     */
69
    public function toMail($notifiable)
70
    {
71
        return (new MailMessage)
72
            ->greeting('Hello ' . $this->server->user . '!')
73
            ->line('You have been added as a subuser for the following server, allowing you certain control over the server.')
74
            ->line('Server Name: ' . $this->server->name)
75
            ->action('Visit Server', route('server.index', $this->server->uuidShort));
76
    }
77
}

app/Notifications/RemovedFromServer.php 1 location

@@ 32-75 (lines=44) @@
29
use Illuminate\Contracts\Queue\ShouldQueue;
30
use Illuminate\Notifications\Messages\MailMessage;
31
32
class RemovedFromServer extends Notification implements ShouldQueue
33
{
34
    use Queueable;
35
36
    /**
37
     * @var object
38
     */
39
    public $server;
40
41
    /**
42
     * Create a new notification instance.
43
     *
44
     * @param  array  $server
45
     * @return void
46
     */
47
    public function __construct(array $server)
48
    {
49
        $this->server = (object) $server;
50
    }
51
52
    /**
53
     * Get the notification's delivery channels.
54
     *
55
     * @param  mixed  $notifiable
56
     * @return array
57
     */
58
    public function via($notifiable)
59
    {
60
        return ['mail'];
61
    }
62
63
    /**
64
     * Get the mail representation of the notification.
65
     *
66
     * @param  mixed  $notifiable
67
     * @return \Illuminate\Notifications\Messages\MailMessage
68
     */
69
    public function toMail($notifiable)
70
    {
71
        return (new MailMessage)
72
            ->error()
73
            ->greeting('Hello ' . $this->server->user . '.')
74
            ->line('You have been removed as a subuser for the following server.')
75
            ->line('Server Name: ' . $this->server->name)
76
            ->action('Visit Panel', route('index'));
77
    }
78
}

app/Notifications/SendPasswordReset.php 1 location

@@ 32-78 (lines=47) @@
29
use Illuminate\Contracts\Queue\ShouldQueue;
30
use Illuminate\Notifications\Messages\MailMessage;
31
32
class SendPasswordReset extends Notification implements ShouldQueue
33
{
34
    use Queueable;
35
36
    /**
37
     * The password reset token.
38
     *
39
     * @var string
40
     */
41
    public $token;
42
43
    /**
44
     * Create a new notification instance.
45
     *
46
     * @param  string  $token
47
     * @return void
48
     */
49
    public function __construct($token)
50
    {
51
        $this->token = $token;
52
    }
53
54
    /**
55
     * Get the notification's delivery channels.
56
     *
57
     * @param  mixed  $notifiable
58
     * @return array
59
     */
60
    public function via($notifiable)
61
    {
62
        return ['mail'];
63
    }
64
65
    /**
66
     * Get the mail representation of the notification.
67
     *
68
     * @param  mixed  $notifiable
69
     * @return \Illuminate\Notifications\Messages\MailMessage
70
     */
71
    public function toMail($notifiable)
72
    {
73
        return (new MailMessage)
74
            ->subject('Reset Password')
75
            ->line('You are receiving this email because we received a password reset request for your account.')
76
            ->action('Reset Password', url('/auth/password/reset/' . $this->token . '?email=' . $notifiable->email))
77
            ->line('If you did not request a password reset, no further action is required.');
78
    }
79
}
80