Skip to content

Commit 4f66ccb

Browse files
authored
Merge pull request #20 from OxCom/develop
fix deprecation notice
2 parents 6c55d7d + 93b2292 commit 4f66ccb

File tree

3 files changed

+14
-10
lines changed

3 files changed

+14
-10
lines changed

DependencyInjection/Configuration.php

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,14 @@ class Configuration implements ConfigurationInterface
6161
*/
6262
public function getConfigTreeBuilder()
6363
{
64-
$treeBuilder = new TreeBuilder();
65-
$rootNode = $treeBuilder->root(SymfonyRollbarExtension::ALIAS);
64+
if (method_exists(TreeBuilder::class, 'getRootNode')) {
65+
$treeBuilder = new TreeBuilder(SymfonyRollbarExtension::ALIAS);
66+
$rootNode = $treeBuilder->getRootNode();
67+
} else {
68+
$treeBuilder = new TreeBuilder();
69+
$rootNode = $treeBuilder->root(SymfonyRollbarExtension::ALIAS);
70+
}
71+
6672
$defaultErrorMask = E_ERROR | E_WARNING | E_PARSE | E_CORE_ERROR | E_USER_ERROR | E_RECOVERABLE_ERROR;
6773

6874
$rootNode

Provider/AbstractPersonProvider.php

100644100755
Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,18 @@
55
use Symfony\Component\DependencyInjection\ContainerInterface;
66
use SymfonyRollbarBundle\Provider\PersonInterface;
77

8+
/**
9+
* Class AbstractPersonProvider
10+
*
11+
* @package SymfonyRollbarBundle\Provider
12+
*/
813
abstract class AbstractPersonProvider
914
{
1015
/**
1116
* @var \SymfonyRollbarBundle\Provider\PersonInterface
1217
*/
1318
protected $person;
1419

15-
/**
16-
* Initialize current person that should be tracked with Rollbar
17-
*
18-
* @param \Symfony\Component\DependencyInjection\ContainerInterface $container
19-
*/
20-
abstract public function __construct(ContainerInterface $container);
21-
2220
/**
2321
* @return array|null
2422
*/

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
"require": {
3131
"php": ">=5.6",
3232
"monolog/monolog": "^1.23",
33-
"rollbar/rollbar": "^1.3",
33+
"rollbar/rollbar": "^1.6",
3434
"symfony/dependency-injection": "^2.8|~3.0|~4.0",
3535
"symfony/config": "^2.8|~3.0|~4.0",
3636
"symfony/http-kernel": "^2.8|~3.0|~4.0",

0 commit comments

Comments
 (0)