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
28424002
Commit
28424002
authored
Jan 11, 2015
by
Marco Pivetta
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'hotfix/#771-backport-php-5-4-unique-index-exception-error-handling' into 2.5
parents
4067c725
8bfcf683
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
0 deletions
+2
-0
AbstractSQLiteDriver.php
lib/Doctrine/DBAL/Driver/AbstractSQLiteDriver.php
+1
-0
AbstractSQLiteDriverTest.php
...s/Doctrine/Tests/DBAL/Driver/AbstractSQLiteDriverTest.php
+1
-0
No files found.
lib/Doctrine/DBAL/Driver/AbstractSQLiteDriver.php
View file @
28424002
...
...
@@ -42,6 +42,7 @@ abstract class AbstractSQLiteDriver implements Driver, ExceptionConverterDriver
{
if
(
strpos
(
$exception
->
getMessage
(),
'must be unique'
)
!==
false
||
strpos
(
$exception
->
getMessage
(),
'is not unique'
)
!==
false
||
strpos
(
$exception
->
getMessage
(),
'are not unique'
)
!==
false
||
strpos
(
$exception
->
getMessage
(),
'UNIQUE constraint failed'
)
!==
false
)
{
return
new
Exception\UniqueConstraintViolationException
(
$message
,
$exception
);
...
...
tests/Doctrine/Tests/DBAL/Driver/AbstractSQLiteDriverTest.php
View file @
28424002
...
...
@@ -71,6 +71,7 @@ class AbstractSQLiteDriverTest extends AbstractDriverTest
self
::
EXCEPTION_UNIQUE_CONSTRAINT_VIOLATION
=>
array
(
array
(
null
,
null
,
'must be unique'
),
array
(
null
,
null
,
'is not unique'
),
array
(
null
,
null
,
'are not unique'
),
),
);
}
...
...
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