Passed
Push — develop ( 60641a...1612eb )
by Csaba
58s
created

Finder::get()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 5
c 0
b 0
f 0
ccs 0
cts 3
cp 0
rs 9.4285
cc 1
eloc 3
nc 1
nop 0
crap 2
1
<?php
2
namespace Fathomminds\Rest\Database\DynamoDb;
3
4
use Fathomminds\Rest\Database\Finder as BaseFinder;
5
use Aws\DynamoDb\DynamoDbClient as Client;
6
use Aws\Sdk;
7
8
class Finder extends BaseFinder
9
{
10
    public function get()
11
    {
12
        $this->resultSet = [];
13
        return $this;
14
    }
15
16
    protected function createClient()
17
    {
18
        $sdk = new Sdk([
19
            'region' => getenv('AWS_SDK_REGION'),
20
            'version' => getenv('AWS_SDK_VERSION'),
21
            'http' => [
22
                'verify' => getenv('AWS_SDK_HTTP_VERIFY') === 'false' ? false : getenv('AWS_SDK_HTTP_VERIFY'),
23
            ]
24
        ]);
25
        $this->client = $sdk->createDynamoDb();
26
        return $this;
27
    }
28
}
29