Replace AmazonS3 create boolean param with array one. Changed
composer.json
This commit is contained in:
parent
6bfca8a96e
commit
f27138e80b
|
@ -18,12 +18,14 @@ class AmazonS3AdapterFactory implements AdapterFactoryInterface
|
||||||
*/
|
*/
|
||||||
public function create(ContainerBuilder $container, $id, array $config)
|
public function create(ContainerBuilder $container, $id, array $config)
|
||||||
{
|
{
|
||||||
$container
|
$definition = $container
|
||||||
->setDefinition($id, new DefinitionDecorator('knp_gaufrette.adapter.amazon_s3'))
|
->setDefinition($id, new DefinitionDecorator('knp_gaufrette.adapter.amazon_s3'))
|
||||||
->addArgument(new Reference($config['amazon_s3_id']))
|
->addArgument(new Reference($config['amazon_s3_id']))
|
||||||
->addArgument($config['bucket_name'])
|
->addArgument($config['bucket_name']);
|
||||||
->addArgument($config['create'])
|
|
||||||
;
|
if (isset($config['options'])) {
|
||||||
|
$definition->addArgument($config['options']);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -47,8 +49,16 @@ class AmazonS3AdapterFactory implements AdapterFactoryInterface
|
||||||
->children()
|
->children()
|
||||||
->scalarNode('amazon_s3_id')->isRequired()->cannotBeEmpty()->end()
|
->scalarNode('amazon_s3_id')->isRequired()->cannotBeEmpty()->end()
|
||||||
->scalarNode('bucket_name')->isRequired()->cannotBeEmpty()->end()
|
->scalarNode('bucket_name')->isRequired()->cannotBeEmpty()->end()
|
||||||
->booleanNode('create')->defaultFalse()->end()
|
->arrayNode('options')
|
||||||
|
->children()
|
||||||
|
->booleanNode('create')
|
||||||
|
->defaultFalse()
|
||||||
|
->end()
|
||||||
|
->scalarNode('region')->end()
|
||||||
|
->scalarNode('directory')->end()
|
||||||
|
->end()
|
||||||
|
->end()
|
||||||
->end()
|
->end()
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
],
|
],
|
||||||
"require": {
|
"require": {
|
||||||
"symfony/framework-bundle": "2.*",
|
"symfony/framework-bundle": "2.*",
|
||||||
"knplabs/gaufrette": "0.1.3"
|
"knplabs/gaufrette": "*"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"symfony/yaml": "2.*",
|
"symfony/yaml": "2.*",
|
||||||
|
@ -28,5 +28,10 @@
|
||||||
"Knp\\Bundle\\GaufretteBundle": ""
|
"Knp\\Bundle\\GaufretteBundle": ""
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"extra": {
|
||||||
|
"branch-alias": {
|
||||||
|
"dev-master": "0.2.x-dev"
|
||||||
|
}
|
||||||
|
},
|
||||||
"target-dir": "Knp/Bundle/GaufretteBundle"
|
"target-dir": "Knp/Bundle/GaufretteBundle"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user