8000 Coding standards and removing whitespace. · mshtukin/symfony@79793e4 · GitHub
[go: up one dir, main page]

Skip to content

Commit 79793e4

Browse files
author
Drak
committed
Coding standards and removing whitespace.
1 parent b498138 commit 79793e4

File tree

9 files changed

+20
-20
lines changed

9 files changed

+20
-20
lines changed

src/Symfony/Bridge/Doctrine/Form/ChoiceList/EntityChoiceList.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ protected function load()
132132

133133
if (is_array($this->choices)) {
134134
$entities = $this->choices;
135-
} else if ($entityLoader = $this->entityLoader) {
135+
} elseif ($entityLoader = $this->entityLoader) {
136136
$entities = $entityLoader->getEntities();
137137
} else {
138138
$entities = $this->em->getRepository($this->class)->findAll();

src/Symfony/Bridge/Doctrine/Form/ChoiceList/EntityLoaderInterface.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@
1313

1414
/**
1515
* Custom loader for entities in the choice list.
16-
*
16+
*
1717
* @author Benjamin Eberlei <kontakt@beberlei.de>
1818
*/
1919
interface EntityLoaderInterface
20-
{
20+
{
2121
/**
2222
* Return an array of entities that are valid choices in the corresponding choice list.
23-
*
23+
*
2424
* @return array
2525
*/
2626
function getEntities();

src/Symfony/Bundle/WebProfilerBundle/Resources/views/Collector/time.html.twig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@
127127
if ('section.child' == event.name) {
128128
context.fillStyle = colors.child_sections;
129129
context.fillRect(x + period.begin * ratio, 0, (period.end - period.begin) * ratio, height);
130-
} else if ('section' == event.category) {
130+
} elseif ('section' == event.category) {
131131
context.beginPath();
132132
context.strokeStyle = "#dfdfdf";
133133
context.moveTo(x + period.begin * ratio, 0);
@@ -156,7 +156,7 @@
156156
if (colors[event.name]) {
157157
context.fillStyle = colors[event.name];
158158
context.strokeStyle = colors[event.name];
159-
} else if (colors[event.category]) {
159+
} elseif (colors[event.category]) {
160160
context.fillStyle = colors[event.category];
161161
context.strokeStyle = colors[event.category];
162162
} else {

src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/toolbar_js.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
if (4 === xhr.readyState && 200 === xhr.status && -1 !== xhr.responseText.indexOf('sf-toolbarreset')) {
1515
wdt.innerHTML = xhr.responseText;
1616
wdt.style.display = 'block';
17-
} else if (4 === xhr.readyState && xhr.status != 200) {
17+
} elseif (4 === xhr.readyState && xhr.status != 200) {
1818
confirm('An error occurred while loading the web debug toolbar (' + xhr.status + ': ' + xhr.statusText + ').\n\nDo you want to open the profiler?') && (window.location = '{{ path("_profiler", { "token": token }) }}');
1919
}
2020
};

src/Symfony/Component/HttpKernel/CacheClearer/CacheClearerInterface.php

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

1414
/**
1515
* CacheClearerInterface.
16-
*
16+
*
1717
* @author Dustin Dobervich <ddobervich@gmail.com>
1818
*/
1919
interface CacheClearerInterface

src/Symfony/Component/HttpKernel/CacheClearer/ChainCacheClearer.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
/**
1515
* ChainCacheClearer.
16-
*
16+
*
1717
* @author Dustin Dobervich <ddobervich@gmail.com>
1818
*/
1919
class ChainCacheClearer implements CacheClearerInterface
@@ -32,7 +32,7 @@ public function __construct(array $clearers = array())
3232
{
3333
$this->clearers = $clearers;
3434
}
35-
35+
3636
/**
3737
* {@inheritDoc}
3838
*/
@@ -42,11 +42,11 @@ public function clear($cacheDir)
4242
$clearer->clear($cacheDir);
4343
}
4444
}
45-
45+
4646
/**
4747
* Adds a cache clearer to the aggregate.
48-
*
49-
* @param CacheClearerInterface $clearer
48+
*
49+
* @param CacheClearerInterface $clearer
5050
*/
5151
public function add(CacheClearerInterface $clearer)
5252
{

tests/Symfony/Tests/Bridge/Doctrine/Fixtures/SingleIdentEntity.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ public function __construct($id, $name) {
1919
$this->id = $id;
2020
$this->name = $name;
2121
}
22-
22+
2323
public function __toString()
2424
{
2525
return (string)$this->name;

tests/Symfony/Tests/Bridge/Doctrine/Form/Type/EntityTypeTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ public function testSetDataToUninitializedEntityWithNonRequired()
111111

112112
$this->assertEquals(array(1 => 'Foo', 2 => 'Bar'), $field->createView()->get('choices'));
113113
}
114-
114+
115115
public function testSetDataToUninitializedEntityWithNonRequiredToString()
116116
{
117117
$entity1 = new SingleIdentEntity(1, 'Foo');
@@ -127,7 +127,7 @@ public function testSetDataToUninitializedEntityWithNonRequiredToString()
127127

128128
$this->assertEquals(array("1" => 'Foo', "2" => 'Bar'), $field->createView()->get('choices'));
129129
}
130-
130+
131131
public function testSetDataToUninitializedEntityWithNonRequiredQueryBuilder()
132132
{
133133
$entity1 = new SingleIdentEntity(1, 'Foo');

tests/Symfony/Tests/Component/HttpKernel/CacheClearer/ChainCacheClearerTest.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,23 +34,23 @@ public function testInjectClearersInConstructor()
3434
$clearer
3535
->expects($this->once())
3636
->method('clear');
37-
37+
3838
$chainClearer = new ChainCacheClearer(array($clearer));
3939
$chainClearer->clear(self::$cacheDir);
4040
}
41-
41+
4242
public function testInjectClearerUsingAdd()
4343
{
4444
$clearer = $this->getMockClearer();
4545
$clearer
4646
->expects($this->once())
4747
->method('clear');
48-
48+
4949
$chainClearer = new ChainCacheClearer();
5050
$chainClearer->add($clearer);
5151
$chainClearer->clear(self::$cacheDir);
5252
}
53-
53+
5454
protected function getMockClearer()
5555
{
5656
return $this->getMock('Symfony\Component\HttpKernel\CacheClearer\CacheClearerInterface');

0 commit comments

Comments
 (0)
0