| Conditions | 2 |
| Paths | 2 |
| Total Lines | 12 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 14 | public function init() |
||
| 15 | { |
||
| 16 | parent::init(); |
||
| 17 | $inputName = explode('_', $this->attribute); |
||
| 18 | if (count($inputName) > 1) { |
||
| 19 | $inputName[0] = $inputName[1]; |
||
| 20 | } |
||
| 21 | $this->inputOptions = array_merge([ |
||
| 22 | 'data-braintree-name' => \yii\helpers\Inflector::underscore($inputName[0]), |
||
| 23 | 'autocomplete' => 'off' |
||
| 24 | ], $this->inputOptions); |
||
| 25 | } |
||
| 26 | |||
| 38 |