Removed old resources array property from DI extension classes.
This commit is contained in:
parent
f79e23ffb5
commit
29360a0eea
@ -26,11 +26,6 @@ use Symfony\Component\DependencyInjection\Resource\FileResource;
|
|||||||
*/
|
*/
|
||||||
class DoctrineExtension extends Extension
|
class DoctrineExtension extends Extension
|
||||||
{
|
{
|
||||||
protected $resources = array(
|
|
||||||
'dbal' => 'dbal.xml',
|
|
||||||
'orm' => 'orm.xml',
|
|
||||||
);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the DBAL configuration.
|
* Loads the DBAL configuration.
|
||||||
*
|
*
|
||||||
@ -74,7 +69,7 @@ class DoctrineExtension extends Extension
|
|||||||
{
|
{
|
||||||
if (!$container->hasDefinition('doctrine.dbal.logger')) {
|
if (!$container->hasDefinition('doctrine.dbal.logger')) {
|
||||||
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
||||||
$loader->load($this->resources['dbal']);
|
$loader->load('dbal.xml');
|
||||||
}
|
}
|
||||||
|
|
||||||
$defaultConnectionName = isset($config['default_connection']) ? $config['default_connection'] : $container->getParameter('doctrine.dbal.default_connection');
|
$defaultConnectionName = isset($config['default_connection']) ? $config['default_connection'] : $container->getParameter('doctrine.dbal.default_connection');
|
||||||
@ -209,7 +204,7 @@ class DoctrineExtension extends Extension
|
|||||||
{
|
{
|
||||||
if (!$container->hasDefinition('doctrine.orm.metadata_driver.annotation')) {
|
if (!$container->hasDefinition('doctrine.orm.metadata_driver.annotation')) {
|
||||||
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
||||||
$loader->load($this->resources['orm']);
|
$loader->load('orm.xml');
|
||||||
}
|
}
|
||||||
|
|
||||||
// Allow these application configuration options to override the defaults
|
// Allow these application configuration options to override the defaults
|
||||||
|
@ -18,10 +18,6 @@ use Symfony\Component\DependencyInjection\Resource\FileResource;
|
|||||||
*/
|
*/
|
||||||
class DoctrineMongoDBExtension extends Extension
|
class DoctrineMongoDBExtension extends Extension
|
||||||
{
|
{
|
||||||
protected $resources = array(
|
|
||||||
'mongodb' => 'mongodb.xml',
|
|
||||||
);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the MongoDB ODM configuration.
|
* Loads the MongoDB ODM configuration.
|
||||||
*
|
*
|
||||||
@ -67,7 +63,7 @@ class DoctrineMongoDBExtension extends Extension
|
|||||||
if (!$container->hasDefinition('doctrine.odm.mongodb.metadata.annotation')) {
|
if (!$container->hasDefinition('doctrine.odm.mongodb.metadata.annotation')) {
|
||||||
// Load DoctrineMongoDBBundle/Resources/config/mongodb.xml
|
// Load DoctrineMongoDBBundle/Resources/config/mongodb.xml
|
||||||
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
||||||
$loader->load($this->resources['mongodb']);
|
$loader->load('mongodb.xml');
|
||||||
}
|
}
|
||||||
|
|
||||||
// Allow these application configuration options to override the defaults
|
// Allow these application configuration options to override the defaults
|
||||||
|
@ -10,10 +10,6 @@ use Symfony\Component\DependencyInjection\Reference;
|
|||||||
|
|
||||||
class PropelExtension extends Extension
|
class PropelExtension extends Extension
|
||||||
{
|
{
|
||||||
protected $resources = array(
|
|
||||||
'propel' => 'propel.xml',
|
|
||||||
);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the Propel configuration.
|
* Loads the Propel configuration.
|
||||||
*
|
*
|
||||||
@ -24,7 +20,7 @@ class PropelExtension extends Extension
|
|||||||
{
|
{
|
||||||
if (!$container->hasDefinition('propel')) {
|
if (!$container->hasDefinition('propel')) {
|
||||||
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
||||||
$loader->load($this->resources['propel']);
|
$loader->load('propel.xml');
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$container->hasParameter('propel.path')) {
|
if (!$container->hasParameter('propel.path')) {
|
||||||
@ -54,7 +50,7 @@ class PropelExtension extends Extension
|
|||||||
{
|
{
|
||||||
if (!$container->hasDefinition('propel')) {
|
if (!$container->hasDefinition('propel')) {
|
||||||
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
||||||
$loader->load($this->resources['propel']);
|
$loader->load('propel.xml');
|
||||||
}
|
}
|
||||||
|
|
||||||
$defaultConnection = array(
|
$defaultConnection = array(
|
||||||
|
@ -23,10 +23,6 @@ use Symfony\Component\DependencyInjection\Reference;
|
|||||||
*/
|
*/
|
||||||
class SwiftMailerExtension extends Extension
|
class SwiftMailerExtension extends Extension
|
||||||
{
|
{
|
||||||
protected $resources = array(
|
|
||||||
'mailer' => 'swiftmailer.xml',
|
|
||||||
);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the Swift Mailer configuration.
|
* Loads the Swift Mailer configuration.
|
||||||
*
|
*
|
||||||
@ -45,7 +41,7 @@ class SwiftMailerExtension extends Extension
|
|||||||
{
|
{
|
||||||
if (!$container->hasDefinition('swiftmailer.mailer')) {
|
if (!$container->hasDefinition('swiftmailer.mailer')) {
|
||||||
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
$loader = new XmlFileLoader($container, __DIR__.'/../Resources/config');
|
||||||
$loader->load($this->resources['mailer']);
|
$loader->load('swiftmailer.xml');
|
||||||
$container->setAlias('mailer', 'swiftmailer.mailer');
|
$container->setAlias('mailer', 'swiftmailer.mailer');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user