Skip to content

Commit e3220b5

Browse files
committed
Convert return types to native ones
1 parent b09fa85 commit e3220b5

File tree

181 files changed

+443
-1454
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

181 files changed

+443
-1454
lines changed

src/Symfony/Bridge/Doctrine/DataCollector/DoctrineDataCollector.php

Lines changed: 5 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -71,42 +71,27 @@ public function reset()
7171
$this->debugDataHolder->reset();
7272
}
7373

74-
/**
75-
* @return array
76-
*/
77-
public function getManagers()
74+
public function getManagers(): array
7875
{
7976
return $this->data['managers'];
8077
}
8178

82-
/**
83-
* @return array
84-
*/
85-
public function getConnections()
79+
public function getConnections(): array
8680
{
8781
return $this->data['connections'];
8882
}
8983

90-
/**
91-
* @return int
92-
*/
93-
public function getQueryCount()
84+
public function getQueryCount(): int
9485
{
9586
return array_sum(array_map('count', $this->data['queries']));
9687
}
9788

98-
/**
99-
* @return array
100-
*/
101-
public function getQueries()
89+
public function getQueries(): array
10290
{
10391
return $this->data['queries'];
10492
}
10593

106-
/**
107-
* @return int
108-
*/
109-
public function getTime()
94+
public function getTime(): int
11095
{
11196
$time = 0;
11297
foreach ($this->data['queries'] as $queries) {

src/Symfony/Bridge/Doctrine/DependencyInjection/Security/UserProvider/EntityFactory.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,7 @@ public function create(ContainerBuilder $container, string $id, array $config)
4646
;
4747
}
4848

49-
/**
50-
* @return string
51-
*/
52-
public function getKey()
49+
public function getKey(): string
5350
{
5451
return $this->key;
5552
}

src/Symfony/Bridge/Doctrine/Form/DoctrineOrmTypeGuesser.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ public function guessPattern(string $class, string $property): ?ValueGuess
159159
*
160160
* @return array{0:ClassMetadata<T>, 1:string}|null
161161
*/
162-
protected function getMetadata(string $class)
162+
protected function getMetadata(string $class): ?array
163163
{
164164
// normalize class name
165165
$class = self::getRealClass(ltrim($class, '\\'));

src/Symfony/Bundle/FrameworkBundle/Secrets/AbstractVault.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,7 @@ protected function validateName(string $name): void
4040
}
4141
}
4242

43-
/**
44-
* @return string
45-
*/
46-
protected function getPrettyPath(string $path)
43+
protected function getPrettyPath(string $path): string
4744
{
4845
return str_replace(getcwd().\DIRECTORY_SEPARATOR, '', $path);
4946
}

src/Symfony/Bundle/FrameworkBundle/Test/KernelTestCase.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,8 @@ protected static function bootKernel(array $options = []): KernelInterface
8585
*
8686
* Using this method is the best way to get a container from your test code.
8787
*
88-
* @return Container
8988
*/
90-
protected static function getContainer(): ContainerInterface
89+
protected static function getContainer(): Container
9190
{
9291
if (!static::$booted) {
9392
static::bootKernel();

src/Symfony/Bundle/SecurityBundle/Debug/TraceableFirewallListener.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,7 @@ final class TraceableFirewallListener extends FirewallListener
2828
private array $wrappedListeners = [];
2929
private array $authenticatorsInfo = [];
3030

31-
/**
32-
* @return array
33-
*/
34-
public function getWrappedListeners()
31+
public function getWrappedListeners(): array
3532
{
3633
return $this->wrappedListeners;
3734
}

src/Symfony/Bundle/SecurityBundle/DependencyInjection/Security/Factory/AbstractFactory.php

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -75,10 +75,7 @@ public function addConfiguration(NodeDefinition $node)
7575
}
7676
}
7777

78-
/**
79-
* @return string
80-
*/
81-
protected function createAuthenticationSuccessHandler(ContainerBuilder $container, string $id, array $config)
78+
protected function createAuthenticationSuccessHandler(ContainerBuilder $container, string $id, array $config): string
8279
{
8380
$successHandlerId = $this->getSuccessHandlerId($id);
8481
$options = array_intersect_key($config, $this->defaultSuccessHandlerOptions);
@@ -97,10 +94,7 @@ protected function createAuthenticationSuccessHandler(ContainerBuilder $containe
9794
return $successHandlerId;
9895
}
9996

100-
/**
101-
* @return string
102-
*/
103-
protected function createAuthenticationFailureHandler(ContainerBuilder $container, string $id, array $config)
97+
protected function createAuthenticationFailureHandler(ContainerBuilder $container, string $id, array $config): string
10498
{
10599
$id = $this->getFailureHandlerId($id);
106100
$options = array_intersect_key($config, $this->defaultFailureHandlerOptions);
@@ -117,18 +111,12 @@ protected function createAuthenticationFailureHandler(ContainerBuilder $containe
117111
return $id;
118112
}
119113

120-
/**
121-
* @return string
122-
*/
123-
protected function getSuccessHandlerId(string $id)
114+
protected function getSuccessHandlerId(string $id): string
124115
{
125116
return 'security.authentication.success_handler.'.$id.'.'.str_replace('-', '_', $this->getKey());
126117
}
127118

128-
/**
129-
* @return string
130-
*/
131-
protected function getFailureHandlerId(string $id)
119+
protected function getFailureHandlerId(string $id): string
132120
{
133121
return 'security.authentication.failure_handler.'.$id.'.'.str_replace('-', '_', $this->getKey());
134122
}

src/Symfony/Bundle/SecurityBundle/DependencyInjection/Security/UserProvider/InMemoryFactory.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,7 @@ public function create(ContainerBuilder $container, string $id, array $config)
4040
$definition->addArgument($users);
4141
}
4242

43-
/**
44-
* @return string
45-
*/
46-
public function getKey()
43+
public function getKey(): string
4744
{
4845
return 'memory';
4946
}

src/Symfony/Bundle/SecurityBundle/DependencyInjection/Security/UserProvider/LdapFactory.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,7 @@ public function create(ContainerBuilder $container, string $id, array $config)
4343
;
4444
}
4545

46-
/**
47-
* @return string
48-
*/
49-
public function getKey()
46+
public function getKey(): string
5047
{
5148
return 'ldap';
5249
}

src/Symfony/Bundle/SecurityBundle/DependencyInjection/Security/UserProvider/UserProviderFactoryInterface.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,7 @@ interface UserProviderFactoryInterface
2727
*/
2828
public function create(ContainerBuilder $container, string $id, array $config);
2929

30-
/**
31-
* @return string
32-
*/
33-
public function getKey();
30+
public function getKey(): string;
3431

3532
/**
3633
* @return void

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy