| Conditions | 1 |
| Paths | 1 |
| Total Lines | 11 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 61 | public function getIdentity(AccessTokenInterface $accessToken) |
||
| 62 | { |
||
| 63 | $response = $this->request('GET', 'user', [], $accessToken); |
||
| 64 | |||
| 65 | $hydrator = new ArrayHydrator([ |
||
| 66 | 'user_id' => 'id', |
||
| 67 | 'name' => 'fullname', |
||
| 68 | 'avatar_url' => 'pictureURL' |
||
| 69 | ]); |
||
| 70 | |||
| 71 | return $hydrator->hydrate(new User(), $response); |
||
| 72 | } |
||
| 74 |