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
32803b92
Unverified
Commit
32803b92
authored
May 30, 2019
by
Gabriel Ostrolucký
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make LoggerChain use constructor to add loggers instead of adder method
parent
a2450fb0
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
0 deletions
+14
-0
UPGRADE.md
UPGRADE.md
+4
-0
LoggerChain.php
lib/Doctrine/DBAL/Logging/LoggerChain.php
+10
-0
No files found.
UPGRADE.md
View file @
32803b92
...
@@ -42,6 +42,10 @@ The `Doctrine\DBAL\Driver\SQLSrv\SQLSrvStatement::LAST_INSERT_ID_SQL` constant
...
@@ -42,6 +42,10 @@ The `Doctrine\DBAL\Driver\SQLSrv\SQLSrvStatement::LAST_INSERT_ID_SQL` constant
The constants in
`Doctrine\DBAL\SQLParserUtils`
have been deprecated and will be made private in 3.0.
The constants in
`Doctrine\DBAL\SQLParserUtils`
have been deprecated and will be made private in 3.0.
## Deprecated `LoggerChain::addLogger` method
The
`Doctrine\DBAL\Logging\LoggerChain::addLogger`
method has been deprecated. Inject list of loggers via constructor instead.
# Upgrade to 2.9
# Upgrade to 2.9
## Deprecated `Statement::fetchColumn()` with an invalid index
## Deprecated `Statement::fetchColumn()` with an invalid index
...
...
lib/Doctrine/DBAL/Logging/LoggerChain.php
View file @
32803b92
...
@@ -10,9 +10,19 @@ class LoggerChain implements SQLLogger
...
@@ -10,9 +10,19 @@ class LoggerChain implements SQLLogger
/** @var SQLLogger[] */
/** @var SQLLogger[] */
private
$loggers
=
[];
private
$loggers
=
[];
/**
* @param SQLLogger[] $loggers
*/
public
function
__construct
(
array
$loggers
=
[])
{
$this
->
loggers
=
$loggers
;
}
/**
/**
* Adds a logger in the chain.
* Adds a logger in the chain.
*
*
* @deprecated Inject list of loggers via constructor instead
*
* @return void
* @return void
*/
*/
public
function
addLogger
(
SQLLogger
$logger
)
public
function
addLogger
(
SQLLogger
$logger
)
...
...
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