Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
d04026ff
Unverified
Commit
d04026ff
authored
Jun 01, 2019
by
Sergei Morozov
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3584 from ostrolucky/rem-addlogger
Remove LoggerChain::addLogger
parents
72a5e9ff
c244c4e3
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
18 deletions
+6
-18
UPGRADE.md
UPGRADE.md
+1
-0
LoggerChain.php
lib/Doctrine/DBAL/Logging/LoggerChain.php
+3
-13
LoggerChainTest.php
tests/Doctrine/Tests/DBAL/Logging/LoggerChainTest.php
+2
-5
No files found.
UPGRADE.md
View file @
d04026ff
...
...
@@ -53,6 +53,7 @@ The `Doctrine\DBAL\Driver::getName()` has been removed.
*
Removed
`Table::addUnnamedForeignKeyConstraint()`
and
`Table::addNamedForeignKeyConstraint()`
.
*
Removed
`Table::renameColumn()`
.
*
Removed
`SQLParserUtils::getPlaceholderPositions()`
.
*
Removed
`LoggerChain::addLogger`
.
*
Removed
`AbstractSchemaManager::getFilterSchemaAssetsExpression()`
,
`Configuration::getFilterSchemaAssetsExpression()`
and
`Configuration::getFilterSchemaAssetsExpression()`
.
*
`SQLParserUtils::*_TOKEN`
constants made private.
...
...
lib/Doctrine/DBAL/Logging/LoggerChain.php
View file @
d04026ff
...
...
@@ -9,27 +9,17 @@ namespace Doctrine\DBAL\Logging;
*/
final
class
LoggerChain
implements
SQLLogger
{
/** @var
SQLLogger[]
*/
/** @var
iterable<SQLLogger>
*/
private
$loggers
=
[];
/**
* @param
SQLLogger[]
$loggers
* @param
iterable<SQLLogger>
$loggers
*/
public
function
__construct
(
array
$loggers
=
[])
public
function
__construct
(
iterable
$loggers
=
[])
{
$this
->
loggers
=
$loggers
;
}
/**
* Adds a logger in the chain.
*
* @deprecated Inject list of loggers via constructor instead
*/
public
function
addLogger
(
SQLLogger
$logger
)
:
void
{
$this
->
loggers
[]
=
$logger
;
}
/**
* {@inheritdoc}
*/
...
...
tests/Doctrine/Tests/DBAL/Logging/LoggerChainTest.php
View file @
d04026ff
...
...
@@ -32,13 +32,10 @@ class LoggerChainTest extends TestCase
*/
private
function
createChain
(
string
$method
,
...
$args
)
:
LoggerChain
{
$chain
=
new
LoggerChain
([
return
new
LoggerChain
([
$this
->
createLogger
(
$method
,
...
$args
),
$this
->
createLogger
(
$method
,
...
$args
),
]);
$chain
->
addLogger
(
$this
->
createLogger
(
$method
,
...
$args
));
return
$chain
;
}
/**
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment