Completed
Push — master ( 9a4a9d...9fe695 )
by Paweł
02:34 queued 10s
created

AccountDetails::config()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 19
Code Lines 17

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 17
c 0
b 0
f 0
dl 0
loc 19
rs 9.7
cc 1
nc 1
nop 0
1
<?php
2
/**
3
 * Created for IG Client.
4
 * User: jakim <[email protected]>
5
 * Date: 14.03.2018
6
 */
7
8
namespace Jakim\Mapper;
9
10
11
use Jakim\Base\Mapper;
12
use Jakim\Model\Account;
13
14
/**
15
 * Account SharedData.
16
 *
17
 * @package Jakim\Mapper
18
 */
19
class AccountDetails extends Mapper
20
{
21
    public function config(): array
22
    {
23
        return [
24
            'class' => Account::class,
25
            'envelope' => 'entry_data.ProfilePage.0.graphql.user',
26
            'properties' => [
27
                'biography' => 'biography',
28
                'externalUrl' => 'external_url',
29
                'followedBy' => 'edge_followed_by.count',
30
                'follows' => 'edge_follow.count',
31
                'fullName' => 'full_name',
32
                'id' => 'id',
33
                'isPrivate' => 'is_private',
34
                'profilePicUrl' => 'profile_pic_url_hd',
35
                'username' => 'username',
36
                'media' => 'edge_owner_to_timeline_media.count',
37
                'isVerified' => 'is_verified',
38
                'isBusiness' => 'is_business_account',
39
                'businessCategory' => 'business_category_name',
40
            ],
41
        ];
42
    }
43
}