Passed
Push — master ( 98541d...d359a0 )
by
unknown
08:18
created

SendAttachment::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 4

Duplication

Lines 6
Ratio 100 %

Code Coverage

Tests 5
CRAP Score 1

Importance

Changes 0
Metric Value
dl 6
loc 6
c 0
b 0
f 0
cc 1
eloc 4
nc 1
nop 3
ccs 5
cts 5
cp 1
crap 1
rs 9.4285
1
<?php
2
3
declare(strict_types=1);
4
5
namespace FondBot\Foundation\Commands;
6
7
use FondBot\Drivers\Chat;
8
use FondBot\Drivers\User;
9
use Illuminate\Bus\Queueable;
10
use FondBot\Templates\Attachment;
11
use Illuminate\Queue\InteractsWithQueue;
12
use Illuminate\Contracts\Queue\ShouldQueue;
13
14 View Code Duplication
class SendAttachment implements ShouldQueue
0 ignored issues
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
15
{
16
    use InteractsWithQueue, Queueable;
17
18
    private $chat;
19
    private $recipient;
20
    private $attachment;
21
22 3
    public function __construct(Chat $chat, User $recipient, Attachment $attachment)
23
    {
24 3
        $this->chat = $chat;
25 3
        $this->recipient = $recipient;
26 3
        $this->attachment = $attachment;
27 3
    }
28
29
    public function handle(): void
30
    {
31
        // TODO
32
    }
33
}
34