Added default values in PropelExtension

This commit is contained in:
William DURAND 2011-01-30 22:37:30 +01:00
parent f9b4daf1e4
commit 1a5b615f4d

View file

@ -66,7 +66,15 @@ class PropelExtension extends Extension
'default_connection' => 'default',
);
$className = $container->getParameter('kernel.debug') ? 'DebugPDO' : 'PropelPDO';
if (!$container->hasParameter('propel.charset')) {
$container->setParameter('propel.charset', 'utf8');
}
if ($container->hasParameter('kernel.debug')) {
$className = $container->getParameter('kernel.debug') ? 'DebugPDO' : 'PropelPDO';
} else {
$className = 'PropelPDO';
}
$defaultConnection = array(
'driver' => 'mysql',