Skip to content

Commit

Permalink
[Foundation] added kernel.bundles to the list of default parameters o…
Browse files Browse the repository at this point in the history
…f the DIC
  • Loading branch information
fabpot committed Feb 22, 2010
1 parent 62c2ef6 commit 0dcaabf
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/Symfony/Foundation/Kernel.php
Expand Up @@ -180,6 +180,12 @@ public function getParameters()

public function getDefaultParameters()
{
$bundles = array();
foreach ($this->bundles as $bundle)
{
$bundles[] = get_class($bundle);
}

return array_merge(
array(
'kernel.root_dir' => $this->rootDir,
Expand All @@ -189,6 +195,7 @@ public function getDefaultParameters()
'kernel.cache_dir' => $this->rootDir.'/cache/'.$this->environment,
'kernel.logs_dir' => $this->rootDir.'/logs',
'kernel.bundle_dirs' => $this->bundleDirs,
'kernel.bundles' => $bundles,
'kernel.charset' => 'UTF-8',
),
$this->getEnvParameters(),
Expand Down
7 changes: 7 additions & 0 deletions src/Symfony/Foundation/bootstrap.php
Expand Up @@ -448,6 +448,12 @@ public function getParameters()

public function getDefaultParameters()
{
$bundles = array();
foreach ($this->bundles as $bundle)
{
$bundles[] = get_class($bundle);
}

return array_merge(
array(
'kernel.root_dir' => $this->rootDir,
Expand All @@ -457,6 +463,7 @@ public function getDefaultParameters()
'kernel.cache_dir' => $this->rootDir.'/cache/'.$this->environment,
'kernel.logs_dir' => $this->rootDir.'/logs',
'kernel.bundle_dirs' => $this->bundleDirs,
'kernel.bundles' => $bundles,
'kernel.charset' => 'UTF-8',
),
$this->getEnvParameters(),
Expand Down

0 comments on commit 0dcaabf

Please sign in to comment.