| Conditions | 3 |
| Paths | 2 |
| Total Lines | 13 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 29 | public function isServerIdAllowed($allowedIds) |
||
| 30 | { |
||
| 31 | $serverId = $this->getServerId(); |
||
| 32 | |||
| 33 | if (empty($serverId)) { |
||
| 34 | throw new ServerIdNotSet('Server id not set'); |
||
| 35 | } |
||
| 36 | |||
| 37 | if (!is_array($allowedIds)) { |
||
| 38 | $allowedIds = [$allowedIds]; |
||
| 39 | } |
||
| 40 | |||
| 41 | return in_array($serverId, $allowedIds); |
||
| 42 | } |
||
| 66 |