| Conditions | 1 |
| Paths | 1 |
| Total Lines | 9 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 1 |
| Changes | 0 | ||
| 1 | <?php |
||
| 19 | 2 | public function addFieldsToForm(Form $form) |
|
| 20 | { |
||
| 21 | 2 | $form->addText('key', 'redis.hash_form.key.label') |
|
| 22 | 2 | ->setRequired('redis.hash_form.key.required'); |
|
|
|
|||
| 23 | 2 | $form->addText('field', 'redis.hash_form.field.label') |
|
| 24 | 2 | ->setRequired('redis.hash_form.field.required'); |
|
| 25 | 2 | $form->addText('value', 'redis.hash_form.value.label') |
|
| 26 | 2 | ->setRequired('redis.hash_form.value.required'); |
|
| 27 | 2 | } |
|
| 28 | |||
| 38 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: