Conditions | 2 |
Paths | 2 |
Total Lines | 12 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Tests | 8 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
36 | 24 | public function __construct($publicKeyId, $privateKeyFile) |
|
37 | { |
||
38 | 24 | CredentialFilter::publicKeyId($publicKeyId); |
|
39 | 20 | CredentialFilter::privateKeyFile($privateKeyFile); |
|
40 | |||
41 | 16 | $this->publicKeyId = $publicKeyId; |
|
42 | try { |
||
43 | 16 | $this->privateKey = file_get_contents($privateKeyFile); |
|
44 | 16 | } catch (Exception $exception) { |
|
45 | 3 | throw new ClientException( |
|
46 | 3 | $exception->getMessage(), |
|
47 | SDK::INVALID_CREDENTIAL |
||
48 | 3 | ); |
|
76 |