Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Sign in
Toggle navigation
S
Silex
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
common
Silex
Commits
83266af9
Commit
83266af9
authored
Apr 10, 2013
by
alexkappa
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Changed mapping of 'validator.validator_service_ids' to use ternary operator
parent
278c5e01
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
6 deletions
+1
-6
src/Silex/Provider/ValidatorServiceProvider.php
src/Silex/Provider/ValidatorServiceProvider.php
+1
-6
No files found.
src/Silex/Provider/ValidatorServiceProvider.php
View file @
83266af9
...
@@ -59,12 +59,7 @@ class ValidatorServiceProvider implements ServiceProviderInterface
...
@@ -59,12 +59,7 @@ class ValidatorServiceProvider implements ServiceProviderInterface
});
});
$app
[
'validator.validator_factory'
]
=
$app
->
share
(
function
()
use
(
$app
)
{
$app
[
'validator.validator_factory'
]
=
$app
->
share
(
function
()
use
(
$app
)
{
$validators
=
array
();
$validators
=
isset
(
$app
[
'validator.validator_service_ids'
])
?
$app
[
'validator.validator_service_ids'
]
:
array
();
if
(
isset
(
$app
[
'validator.validator_service_ids'
]))
{
foreach
(
$app
[
'validator.validator_service_ids'
]
as
$alias
=>
$service
)
{
$validators
[
$alias
]
=
$service
;
}
}
return
new
ConstraintValidatorFactory
(
$app
,
$validators
);
return
new
ConstraintValidatorFactory
(
$app
,
$validators
);
});
});
...
...
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