Skip to content

Commit b27b0a9

Browse files
minor symfony#19405 Fixed bugs in names of classes and methods. (zomberg)
This PR was squashed before being merged into the 2.7 branch (closes symfony#19405). Discussion ---------- Fixed bugs in names of classes and methods. | Q | A | ------------- | --- | Branch? | 2.7 | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | ~ | License | MIT | Doc PR | ~ It's related to case sensitive. I changed only calls of names of called methods but not definition of methods because BC. Commits ------- c41aa03 Fixed bugs in names of classes and methods.
2 parents 0f07034 + c41aa03 commit b27b0a9

File tree

25 files changed

+32
-32
lines changed

25 files changed

+32
-32
lines changed

src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -823,10 +823,10 @@ private function getValidatorMappingFiles(ContainerBuilder $container)
823823

824824
if (is_dir($dir = $dirname.'/Resources/config/validation')) {
825825
foreach (Finder::create()->files()->in($dir)->name('*.xml') as $file) {
826-
$files[0][] = $file->getRealpath();
826+
$files[0][] = $file->getRealPath();
827827
}
828828
foreach (Finder::create()->files()->in($dir)->name('*.yml') as $file) {
829-
$files[1][] = $file->getRealpath();
829+
$files[1][] = $file->getRealPath();
830830
}
831831

832832
$container->addResource(new DirectoryResource($dir));
@@ -944,13 +944,13 @@ private function registerSerializerConfiguration(array $config, ContainerBuilder
944944

945945
if (is_dir($dir = $dirname.'/Resources/config/serialization')) {
946946
foreach (Finder::create()->files()->in($dir)->name('*.xml') as $file) {
947-
$definition = new Definition('Symfony\Component\Serializer\Mapping\Loader\XmlFileLoader', array($file->getRealpath()));
947+
$definition = new Definition('Symfony\Component\Serializer\Mapping\Loader\XmlFileLoader', array($file->getRealPath()));
948948
$definition->setPublic(false);
949949

950950
$serializerLoaders[] = $definition;
951951
}
952952
foreach (Finder::create()->files()->in($dir)->name('*.yml') as $file) {
953-
$definition = new Definition('Symfony\Component\Serializer\Mapping\Loader\YamlFileLoader', array($file->getRealpath()));
953+
$definition = new Definition('Symfony\Component\Serializer\Mapping\Loader\YamlFileLoader', array($file->getRealPath()));
954954
$definition->setPublic(false);
955955

956956
$serializerLoaders[] = $definition;

src/Symfony/Bundle/FrameworkBundle/Translation/TranslationLoader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ public function loadMessages($directory, MessageCatalogue $catalogue)
5858
$extension = $catalogue->getLocale().'.'.$format;
5959
$files = $finder->files()->name('*.'.$extension)->in($directory);
6060
foreach ($files as $file) {
61-
$domain = substr($file->getFileName(), 0, -1 * strlen($extension) - 1);
61+
$domain = substr($file->getFilename(), 0, -1 * strlen($extension) - 1);
6262
$catalogue->addCatalogue($loader->load($file->getPathname(), $catalogue->getLocale(), $domain));
6363
}
6464
}

src/Symfony/Component/Config/Util/XmlUtils.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ public static function loadFile($file, $schemaOrCallable = null)
123123
*
124124
* @return array A PHP array
125125
*/
126-
public static function convertDomElementToArray(\DomElement $element, $checkPrefix = true)
126+
public static function convertDomElementToArray(\DOMElement $element, $checkPrefix = true)
127127
{
128128
$prefix = (string) $element->prefix;
129129
$empty = true;

src/Symfony/Component/Console/Helper/SymfonyQuestionHelper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ protected function writePrompt(OutputInterface $output, Question $question)
6666

6767
break;
6868

69-
case $question instanceof ChoiceQuestion && $question->isMultiSelect():
69+
case $question instanceof ChoiceQuestion && $question->isMultiselect():
7070
$choices = $question->getChoices();
7171
$default = explode(',', $default);
7272

src/Symfony/Component/Console/Tests/ApplicationTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@ public function testFindAlternativeNamespace()
423423
$application->add(new \FooCommand());
424424
$application->add(new \Foo1Command());
425425
$application->add(new \Foo2Command());
426-
$application->add(new \foo3Command());
426+
$application->add(new \Foo3Command());
427427

428428
try {
429429
$application->find('Unknown-namespace:Unknown-command');

src/Symfony/Component/Debug/Tests/MockExceptionHandler.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
use Symfony\Component\Debug\ExceptionHandler;
1515

16-
class MockExceptionHandler extends Exceptionhandler
16+
class MockExceptionHandler extends ExceptionHandler
1717
{
1818
public $e;
1919

src/Symfony/Component/DependencyInjection/Loader/XmlFileLoader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -564,7 +564,7 @@ private function loadFromExtensions(\DOMDocument $xml)
564564
*
565565
* @return array A PHP array
566566
*/
567-
public static function convertDomElementToArray(\DomElement $element)
567+
public static function convertDomElementToArray(\DOMElement $element)
568568
{
569569
return XmlUtils::convertDomElementToArray($element);
570570
}

src/Symfony/Component/DependencyInjection/Tests/Dumper/PhpDumperTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ public function provideInvalidParameters()
100100
{
101101
return array(
102102
array(array('foo' => new Definition('stdClass'))),
103-
array(array('foo' => new Expression('service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default")'))),
103+
array(array('foo' => new Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")'))),
104104
array(array('foo' => new Reference('foo'))),
105105
array(array('foo' => new Variable('foo'))),
106106
);

src/Symfony/Component/DependencyInjection/Tests/Fixtures/containers/container9.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
->addMethodCall('setBar', array(new Reference('foo2', ContainerInterface::NULL_ON_INVALID_REFERENCE)))
5151
->addMethodCall('setBar', array(new Reference('foo3', ContainerInterface::IGNORE_ON_INVALID_REFERENCE)))
5252
->addMethodCall('setBar', array(new Reference('foobaz', ContainerInterface::IGNORE_ON_INVALID_REFERENCE)))
53-
->addMethodCall('setBar', array(new Expression('service("foo").foo() ~ (container.hasparameter("foo") ? parameter("foo") : "default")')))
53+
->addMethodCall('setBar', array(new Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')))
5454
;
5555
$container
5656
->register('foo_with_inline', 'Foo')

src/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services9.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ protected function getMethodCall1Service()
248248
if ($this->has('foobaz')) {
249249
$instance->setBar($this->get('foobaz', ContainerInterface::NULL_ON_INVALID_REFERENCE));
250250
}
251-
$instance->setBar(($this->get("foo")->foo() . (($this->hasparameter("foo")) ? ($this->getParameter("foo")) : ("default"))));
251+
$instance->setBar(($this->get("foo")->foo() . (($this->hasParameter("foo")) ? ($this->getParameter("foo")) : ("default"))));
252252

253253
return $instance;
254254
}

0 commit comments

Comments
 (0)