Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
drupal
Commits
48ad4e8e
Commit
48ad4e8e
authored
Jul 08, 2012
by
Katherine Bailey
Browse files
Fixing whitespace issues
parent
600a17e8
Changes
3
Hide whitespace changes
Inline
Side-by-side
core/lib/Drupal/Core/DependencyInjection/Compiler/RegisterKernelListenersPass.php
View file @
48ad4e8e
...
...
@@ -15,7 +15,7 @@ class RegisterKernelListenersPass implements CompilerPassInterface
public
function
process
(
ContainerBuilder
$container
)
{
if
(
!
$container
->
hasDefinition
(
'dispatcher'
))
{
return
;
return
;
}
$definition
=
$container
->
getDefinition
(
'dispatcher'
);
...
...
@@ -28,7 +28,7 @@ public function process(ContainerBuilder $container)
$refClass
=
new
\
ReflectionClass
(
$class
);
$interface
=
'Symfony\Component\EventDispatcher\EventSubscriberInterface'
;
if
(
!
$refClass
->
implementsInterface
(
$interface
))
{
throw
new
\
InvalidArgumentException
(
sprintf
(
'Service "%s" must implement interface "%s".'
,
$id
,
$interface
));
throw
new
\
InvalidArgumentException
(
sprintf
(
'Service "%s" must implement interface "%s".'
,
$id
,
$interface
));
}
$definition
->
addMethodCall
(
'addSubscriberService'
,
array
(
$id
,
$class
));
}
...
...
core/lib/Drupal/Core/DependencyInjection/ContainerBuilder.php
View file @
48ad4e8e
...
...
@@ -18,27 +18,27 @@
*/
class
ContainerBuilder
extends
BaseContainerBuilder
{
public
function
addCompilerPass
(
CompilerPassInterface
$pass
,
$type
=
PassConfig
::
TYPE_BEFORE_OPTIMIZATION
)
{
if
(
!
isset
(
$this
->
compiler
)
||
null
===
$this
->
compiler
)
{
$this
->
compiler
=
new
Compiler
();
}
$this
->
compiler
->
addPass
(
$pass
,
$type
);
public
function
addCompilerPass
(
CompilerPassInterface
$pass
,
$type
=
PassConfig
::
TYPE_BEFORE_OPTIMIZATION
)
{
if
(
!
isset
(
$this
->
compiler
)
||
null
===
$this
->
compiler
)
{
$this
->
compiler
=
new
Compiler
();
}
public
function
compile
()
{
if
(
null
===
$this
->
compiler
)
{
$this
->
compiler
=
new
Compiler
();
}
$this
->
compiler
->
compile
(
$this
);
$this
->
parameterBag
->
resolve
();
// TODO: The line below is commented out because there is code that calls
// the set() method on the container after it has been built - that method
// throws an exception if the container's parameters have been frozen.
//$this->parameterBag = new FrozenParameterBag($this->parameterBag->all());
$this
->
compiler
->
addPass
(
$pass
,
$type
);
}
public
function
compile
()
{
if
(
null
===
$this
->
compiler
)
{
$this
->
compiler
=
new
Compiler
();
}
$this
->
compiler
->
compile
(
$this
);
$this
->
parameterBag
->
resolve
();
// TODO: The line below is commented out because there is code that calls
// the set() method on the container after it has been built - that method
// throws an exception if the container's parameters have been frozen.
//$this->parameterBag = new FrozenParameterBag($this->parameterBag->all());
}
}
core/lib/Drupal/Core/DrupalBundle.php
View file @
48ad4e8e
...
...
@@ -214,4 +214,4 @@ function registerLanguageServices($container) {
}
}
}
}
\ No newline at end of file
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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