Skip to content

Commit dcc23ab

Browse files
committed
fixed some deprecation messages
1 parent 2fadb1d commit dcc23ab

31 files changed

+53
-53
lines changed

Compiler/AutowirePass.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ public function process(ContainerBuilder $container)
8181
*/
8282
public static function createResourceForClass(\ReflectionClass $reflectionClass)
8383
{
84-
@trigger_error('The '.__METHOD__.'() method is deprecated since version 3.3 and will be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead.', E_USER_DEPRECATED);
84+
@trigger_error('The '.__METHOD__.'() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead.', E_USER_DEPRECATED);
8585

8686
$metadata = array();
8787

Compiler/Compiler.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ public function getServiceReferenceGraph()
6262
public function getLoggingFormatter()
6363
{
6464
if (null === $this->loggingFormatter) {
65-
@trigger_error(sprintf('The %s() method is deprecated since version 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', __METHOD__), E_USER_DEPRECATED);
65+
@trigger_error(sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', __METHOD__), E_USER_DEPRECATED);
6666

6767
$this->loggingFormatter = new LoggingFormatter();
6868
}
@@ -85,7 +85,7 @@ public function addPass(CompilerPassInterface $pass, $type = PassConfig::TYPE_BE
8585
if (__CLASS__ !== get_class($this)) {
8686
$r = new \ReflectionMethod($this, __FUNCTION__);
8787
if (__CLASS__ !== $r->getDeclaringClass()->getName()) {
88-
@trigger_error(sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since 3.2.', __METHOD__), E_USER_DEPRECATED);
88+
@trigger_error(sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), E_USER_DEPRECATED);
8989
}
9090
}
9191

@@ -104,7 +104,7 @@ public function addPass(CompilerPassInterface $pass, $type = PassConfig::TYPE_BE
104104
*/
105105
public function addLogMessage($string)
106106
{
107-
@trigger_error(sprintf('The %s() method is deprecated since version 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', __METHOD__), E_USER_DEPRECATED);
107+
@trigger_error(sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', __METHOD__), E_USER_DEPRECATED);
108108

109109
$this->log[] = $string;
110110
}

Compiler/FactoryReturnTypePass.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class FactoryReturnTypePass implements CompilerPassInterface
2727
public function __construct(ResolveClassPass $resolveClassPass = null)
2828
{
2929
if (null === $resolveClassPass) {
30-
@trigger_error('The '.__CLASS__.' class is deprecated since version 3.3 and will be removed in 4.0.', E_USER_DEPRECATED);
30+
@trigger_error('The '.__CLASS__.' class is deprecated since Symfony 3.3 and will be removed in 4.0.', E_USER_DEPRECATED);
3131
}
3232
$this->resolveClassPass = $resolveClassPass;
3333
}

Compiler/LoggingFormatter.php

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

1212
namespace Symfony\Component\DependencyInjection\Compiler;
1313

14-
@trigger_error('The '.__NAMESPACE__.'\LoggingFormatter class is deprecated since version 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', E_USER_DEPRECATED);
14+
@trigger_error('The '.__NAMESPACE__.'\LoggingFormatter class is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', E_USER_DEPRECATED);
1515

1616
/**
1717
* Used to format logging messages during the compilation.

Compiler/PassConfig.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ public function addPass(CompilerPassInterface $pass, $type = self::TYPE_BEFORE_O
116116
if (__CLASS__ !== get_class($this)) {
117117
$r = new \ReflectionMethod($this, __FUNCTION__);
118118
if (__CLASS__ !== $r->getDeclaringClass()->getName()) {
119-
@trigger_error(sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since 3.2.', __METHOD__), E_USER_DEPRECATED);
119+
@trigger_error(sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), E_USER_DEPRECATED);
120120
}
121121
}
122122

Compiler/ServiceReferenceGraph.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ public function connect($sourceId, $sourceValue, $destId, $destValue = null, $re
9494
if (__CLASS__ !== get_class($this)) {
9595
$r = new \ReflectionMethod($this, __FUNCTION__);
9696
if (__CLASS__ !== $r->getDeclaringClass()->getName()) {
97-
@trigger_error(sprintf('Method %s() will have a 6th `bool $lazy = false` argument in version 4.0. Not defining it is deprecated since 3.3.', __METHOD__), E_USER_DEPRECATED);
97+
@trigger_error(sprintf('Method %s() will have a 6th `bool $lazy = false` argument in version 4.0. Not defining it is deprecated since Symfony 3.3.', __METHOD__), E_USER_DEPRECATED);
9898
}
9999
}
100100
$lazy = false;

Config/AutowireServiceResource.php

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

1212
namespace Symfony\Component\DependencyInjection\Config;
1313

14-
@trigger_error('The '.__NAMESPACE__.'\AutowireServiceResource class is deprecated since version 3.3 and will be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead.', E_USER_DEPRECATED);
14+
@trigger_error('The '.__NAMESPACE__.'\AutowireServiceResource class is deprecated since Symfony 3.3 and will be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead.', E_USER_DEPRECATED);
1515

1616
use Symfony\Component\Config\Resource\SelfCheckingResourceInterface;
1717
use Symfony\Component\DependencyInjection\Compiler\AutowirePass;

Container.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ public function isCompiled()
110110
*/
111111
public function isFrozen()
112112
{
113-
@trigger_error(sprintf('The %s() method is deprecated since version 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), E_USER_DEPRECATED);
113+
@trigger_error(sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), E_USER_DEPRECATED);
114114

115115
return $this->parameterBag instanceof FrozenParameterBag;
116116
}
@@ -241,7 +241,7 @@ public function has($id)
241241
// We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder,
242242
// and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper)
243243
if (!$this->methodMap && !$this instanceof ContainerBuilder && __CLASS__ !== static::class && method_exists($this, 'get'.strtr($id, $this->underscoreMap).'Service')) {
244-
@trigger_error('Generating a dumped container without populating the method map is deprecated since 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', E_USER_DEPRECATED);
244+
@trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', E_USER_DEPRECATED);
245245

246246
return true;
247247
}
@@ -301,7 +301,7 @@ public function get($id, $invalidBehavior = self::EXCEPTION_ON_INVALID_REFERENCE
301301
} elseif (!$this->methodMap && !$this instanceof ContainerBuilder && __CLASS__ !== static::class && method_exists($this, $method = 'get'.strtr($id, $this->underscoreMap).'Service')) {
302302
// We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder,
303303
// and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper)
304-
@trigger_error('Generating a dumped container without populating the method map is deprecated since 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', E_USER_DEPRECATED);
304+
@trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', E_USER_DEPRECATED);
305305
// $method is set to the right value, proceed
306306
} else {
307307
if (self::EXCEPTION_ON_INVALID_REFERENCE === $invalidBehavior) {
@@ -381,7 +381,7 @@ public function getServiceIds()
381381
if (!$this->methodMap && !$this instanceof ContainerBuilder && __CLASS__ !== static::class) {
382382
// We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder,
383383
// and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper)
384-
@trigger_error('Generating a dumped container without populating the method map is deprecated since 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', E_USER_DEPRECATED);
384+
@trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', E_USER_DEPRECATED);
385385

386386
foreach (get_class_methods($this) as $method) {
387387
if (preg_match('/^get(.+)Service$/', $method, $match)) {
@@ -465,7 +465,7 @@ public function normalizeId($id)
465465
if (isset($this->normalizedIds[$normalizedId = strtolower($id)])) {
466466
$normalizedId = $this->normalizedIds[$normalizedId];
467467
if ($id !== $normalizedId) {
468-
@trigger_error(sprintf('Service identifiers will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since version 3.3.', $id, $normalizedId), E_USER_DEPRECATED);
468+
@trigger_error(sprintf('Service identifiers will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.3.', $id, $normalizedId), E_USER_DEPRECATED);
469469
}
470470
} else {
471471
$normalizedId = $this->normalizedIds[$normalizedId] = $id;

ContainerBuilder.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,7 @@ public function addObjectResource($object)
316316
*/
317317
public function addClassResource(\ReflectionClass $class)
318318
{
319-
@trigger_error('The '.__METHOD__.'() method is deprecated since version 3.3 and will be removed in 4.0. Use the addObjectResource() or the getReflectionClass() method instead.', E_USER_DEPRECATED);
319+
@trigger_error('The '.__METHOD__.'() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the addObjectResource() or the getReflectionClass() method instead.', E_USER_DEPRECATED);
320320

321321
return $this->addObjectResource($class->name);
322322
}
@@ -449,7 +449,7 @@ public function addCompilerPass(CompilerPassInterface $pass, $type = PassConfig:
449449
if (__CLASS__ !== get_class($this)) {
450450
$r = new \ReflectionMethod($this, __FUNCTION__);
451451
if (__CLASS__ !== $r->getDeclaringClass()->getName()) {
452-
@trigger_error(sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since 3.2.', __METHOD__), E_USER_DEPRECATED);
452+
@trigger_error(sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), E_USER_DEPRECATED);
453453
}
454454
}
455455

@@ -710,7 +710,7 @@ public function compile(/*$resolveEnvPlaceholders = false*/)
710710
if (__CLASS__ !== static::class) {
711711
$r = new \ReflectionMethod($this, __FUNCTION__);
712712
if (__CLASS__ !== $r->getDeclaringClass()->getName() && (1 > $r->getNumberOfParameters() || 'resolveEnvPlaceholders' !== $r->getParameters()[0]->name)) {
713-
@trigger_error(sprintf('The %s::compile() method expects a first "$resolveEnvPlaceholders" argument since version 3.3. It will be made mandatory in 4.0.', static::class), E_USER_DEPRECATED);
713+
@trigger_error(sprintf('The %s::compile() method expects a first "$resolveEnvPlaceholders" argument since Symfony 3.3. It will be made mandatory in 4.0.', static::class), E_USER_DEPRECATED);
714714
}
715715
}
716716
$resolveEnvPlaceholders = false;

DefinitionDecorator.php

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

1212
namespace Symfony\Component\DependencyInjection;
1313

14-
@trigger_error('The '.__NAMESPACE__.'\DefinitionDecorator class is deprecated since version 3.3 and will be removed in 4.0. Use the Symfony\Component\DependencyInjection\ChildDefinition class instead.', E_USER_DEPRECATED);
14+
@trigger_error('The '.__NAMESPACE__.'\DefinitionDecorator class is deprecated since Symfony 3.3 and will be removed in 4.0. Use the Symfony\Component\DependencyInjection\ChildDefinition class instead.', E_USER_DEPRECATED);
1515

1616
class_exists(ChildDefinition::class);
1717

0 commit comments

Comments
 (0)