Conditions | 3 |
Paths | 3 |
Total Lines | 10 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
17 | public function setBody($params = null) |
||
18 | { |
||
19 | if (isset($this->_index)) { |
||
20 | if(isset($params['query'])) |
||
21 | { |
||
22 | return parent::setBody(['query' => "EXPLAIN QUERY ".$this->_index. '\''.$params['query'].'\'']); |
||
23 | } |
||
24 | throw new RuntimeException('Query param is missing.'); |
||
25 | } |
||
26 | throw new RuntimeException('Index name is missing.'); |
||
27 | } |
||
44 | } |