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.
Test Failed
Pull Request — master (#3)
by Sascha
04:42
created

Content::hasHtmlContent()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
3
namespace Conversio\Mail;
4
5
/**
6
 * Class Content
7
 * @package Conversio\Mail
8
 */
9
class Content
10
{
11
    /**
12
     * @var string
13
     */
14
    private $html = '';
15
16
    /**
17
     * @var string
18
     */
19
    private $text = '';
20
21
    /**
22
     * @return string
23
     */
24 1
    public function getHtml(): string
25
    {
26 1
        return $this->html;
27
    }
28
29
    /**
30
     * @param string $html
31
     */
32 1
    public function setHtml(string $html)
33
    {
34 1
        $this->html = $html;
35 1
    }
36
37
    /**
38
     * @return string
39
     */
40 1
    public function getText(): string
41
    {
42 1
        return $this->text;
43
    }
44
45
    /**
46
     * @param string $text
47
     */
48 1
    public function setText(string $text)
49
    {
50 1
        $this->text = $text;
51 1
    }
52
53
    /**
54
     * @return bool
55
     */
56 1
    public function hasHtmlContent(): bool
57
    {
58 1
        return $this->html !== '';
59
    }
60
61
    /**
62
     * @return bool
63
     */
64 1
    public function hasTextContent(): bool
65
    {
66 1
        return $this->text !== '';
67
    }
68
}