Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 22c8f80

Browse filesBrowse files
committed
[Form] Fixed issues mentioned in the PR comments
1 parent 3b1b570 commit 22c8f80
Copy full SHA for 22c8f80

File tree

5 files changed

+6
-6
lines changed
Filter options

5 files changed

+6
-6
lines changed

‎UPGRADE-2.1.md

Copy file name to clipboardExpand all lines: UPGRADE-2.1.md
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,14 +237,14 @@ UPGRADE FROM 2.0 to 2.1
237237

238238
Before:
239239

240-
public function getParent()
240+
public function getParent(array $options)
241241
{
242242
return 'single_text' === $options['widget'] ? 'text' : 'choice';
243243
}
244244

245245
After:
246246

247-
public function getParent()
247+
public function getParent(array $options)
248248
{
249249
return isset($options['widget']) && 'single_text' === $options['widget'] ? 'text' : 'choice';
250250
}

‎src/Symfony/Component/Form/Extension/Core/DataTransformer/ChoicesToBooleanArrayTransformer.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Form/Extension/Core/DataTransformer/ChoicesToBooleanArrayTransformer.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ public function reverseTransform($values)
107107
}
108108

109109
if (count($unknown) > 0) {
110-
throw new TransformationFailedException('The choices "' . implode('", "', $unknown) . '" where not found');
110+
throw new TransformationFailedException('The choices "' . implode('", "', $unknown) . '" were not found');
111111
}
112112

113113
return $result;

‎tests/Symfony/Tests/Component/Form/Extension/Core/Type/DateTimeTypeTest.php

Copy file name to clipboardExpand all lines: tests/Symfony/Tests/Component/Form/Extension/Core/Type/DateTimeTypeTest.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,6 +264,6 @@ public function testInitializeWithDateTime()
264264
{
265265
// Throws an exception if "data_class" option is not explicitely set
266266
// to null in the type
267-
$form = $this->factory->create('datetime', new \DateTime());
267+
$this->factory->create('datetime', new \DateTime());
268268
}
269269
}

‎tests/Symfony/Tests/Component/Form/Extension/Core/Type/DateTypeTest.php

Copy file name to clipboardExpand all lines: tests/Symfony/Tests/Component/Form/Extension/Core/Type/DateTypeTest.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -536,6 +536,6 @@ public function testInitializeWithDateTime()
536536
{
537537
// Throws an exception if "data_class" option is not explicitely set
538538
// to null in the type
539-
$form = $this->factory->create('date', new \DateTime());
539+
$this->factory->create('date', new \DateTime());
540540
}
541541
}

‎tests/Symfony/Tests/Component/Form/Extension/Core/Type/TimeTypeTest.php

Copy file name to clipboardExpand all lines: tests/Symfony/Tests/Component/Form/Extension/Core/Type/TimeTypeTest.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,6 +407,6 @@ public function testInitializeWithDateTime()
407407
{
408408
// Throws an exception if "data_class" option is not explicitely set
409409
// to null in the type
410-
$form = $this->factory->create('time', new \DateTime());
410+
$this->factory->create('time', new \DateTime());
411411
}
412412
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.