| 1 | <?php |
||
| 10 | class RedisCreateHashForm implements TableFormInterface |
||
| 11 | { |
||
| 12 | private $connection; |
||
| 13 | |||
| 14 | 2 | public function __construct(RedisProxy $connection) |
|
| 15 | { |
||
| 16 | 2 | $this->connection = $connection; |
|
| 17 | 2 | } |
|
| 18 | |||
| 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 | |||
| 29 | public function submit(Form $form, ArrayHash $values) |
||
| 37 | } |
||
| 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: