Conditions | 5 |
Paths | 16 |
Total Lines | 21 |
Code Lines | 11 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 30 |
Changes | 0 |
1 | <?php |
||
50 | public function toArray() |
||
51 | { |
||
52 | $request = [ |
||
53 | 'include_entities' => $this->includeEntities ? 'true' : 'false', |
||
54 | 'page' => $this->page |
||
55 | ]; |
||
56 | |||
57 | if ($this->count !== null) { |
||
58 | $request['count'] = $this->count; |
||
59 | } |
||
60 | |||
61 | if ($this->fromId !== null) { |
||
62 | $request['since_id'] = $this->fromId; |
||
63 | } |
||
64 | |||
65 | if ($this->toId !== null) { |
||
66 | $request['max_id'] = $this->toId; |
||
67 | } |
||
68 | |||
69 | return $request; |
||
70 | } |
||
71 | } |
||
72 |