Completed
Push — master ( f77348...ad6f80 )
by Sergey
03:41
created

User   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 4
Bugs 0 Features 2
Metric Value
wmc 1
c 4
b 0
f 2
lcom 0
cbo 1
dl 0
loc 20
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A profile() 0 6 1
1
<?php
2
3
namespace seregazhuk\PinterestBot\Api\Providers;
4
5
use seregazhuk\PinterestBot\Helpers\UrlHelper;
6
7
class User extends Provider {
8
9
    protected $loginRequired = ['profile'];
10
11
    /**
12
     * Update user profile info. Gets associative array as
13
     * a params. Available keys of array are:
14
     * 'last_name', 'first_name', 'username', 'about', 'location' and 'website_url'.
15
     *
16
     * @param array $userInfo
17
     * @return mixed
18
     */
19
    public function profile($userInfo)
20
    {
21
        return $this->callPostRequest(
22
            $userInfo, UrlHelper::RESOURCE_UPDATE_USER_SETTINGS
23
        );
24
    }
25
26
}
27