Completed
Push — master ( 7e6ebb...3066b8 )
by Dwight
12s
created

ApnCredentials::certificate()   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 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
cc 1
eloc 2
nc 1
nop 0
crap 1
1
<?php
2
3
namespace NotificationChannels\Apn;
4
5
use Illuminate\Contracts\Config\Repository;
6
7
class ApnCredentials
8
{
9
    /**
10
     * The config repository.
11
     *
12
     * @var \Illuminate\Contracts\Config\Repository
13
     */
14
    protected $config;
15
16
    /**
17
     * Create a new instance of the credentials.
18
     *
19
     * @param  \Illuminate\Contracts\Config\Repository
20
     */
21 6
    public function __construct(Repository $config)
22
    {
23 6
        $this->config = $config;
24 6
    }
25
26
    /**
27
     * Get the APN environment.
28
     *
29
     * @return string
30
     */
31 4
    public function environment()
32
    {
33 4
        return $this->config->get('broadcasting.connections.apn.environment');
34
    }
35
36
    /**
37
     * Get the APN certificate..
38
     *
39
     * @return string
40
     */
41 4
    public function certificate()
42
    {
43 4
        return $this->config->get('broadcasting.connections.apn.certificate');
44
    }
45
46
    /**
47
     * Get the APN pass phrase.
48
     *
49
     * @return string
50
     */
51 4
    public function passPhrase()
52
    {
53 4
        return $this->config->get('broadcasting.connections.apn.pass_phrase');
54
    }
55
}
56