Conditions | 4 |
Paths | 4 |
Total Lines | 10 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 2 | ||
Bugs | 1 | Features | 0 |
1 | <?php namespace CalDAVClient\Facade\Responses; |
||
33 | public function getResponseByType($type){ |
||
34 | $responses = []; |
||
35 | |||
36 | foreach ($this->getResponses() as $response){ |
||
37 | if(!$response instanceof GetCalendarResponse) continue; |
||
38 | $resource_types = $response->getResourceType(); |
||
39 | if(in_array($type, array_keys($resource_types))) $responses[] = $response; |
||
40 | } |
||
41 | |||
42 | return $responses; |
||
43 | } |
||
46 |