Conditions | 1 |
Paths | 1 |
Total Lines | 12 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
35 | protected function bindValues(PDOStatement $statement) |
||
36 | { |
||
37 | $this->resetFields(); |
||
38 | $this->resetPreparedItems(); |
||
39 | $fields = $this->getFields(); |
||
40 | |||
41 | $this->iterateOverItems($this->getPreparedItems(), function ($iteration) use ($statement, $fields) { |
||
42 | $field = current($fields); |
||
43 | $value = $this->getPreparedItems()[$iteration][$field] ?? current($this->getPreparedItems()[$iteration]); |
||
44 | $statement->bindValue(':'.$field.'_'.$iteration, $value); |
||
45 | }); |
||
46 | } |
||
47 | } |
||
48 |