File tree Expand file tree Collapse file tree 2 files changed +3
-19
lines changed Expand file tree Collapse file tree 2 files changed +3
-19
lines changed Original file line number Diff line number Diff line change 337
337
<xsd : element name =" default-psr6-provider" type =" xsd:string" minOccurs =" 0" maxOccurs =" 1" />
338
338
<xsd : element name =" default-redis-provider" type =" xsd:string" minOccurs =" 0" maxOccurs =" 1" />
339
339
<xsd : element name =" default-memcached-provider" type =" xsd:string" minOccurs =" 0" maxOccurs =" 1" />
340
+ <xsd : element name =" default-doctrine-dbal-provider" type =" xsd:string" minOccurs =" 0" maxOccurs =" 1" />
340
341
<xsd : element name =" default-pdo-provider" type =" xsd:string" minOccurs =" 0" maxOccurs =" 1" />
341
342
<xsd : element name =" pool" type =" cache_pool" minOccurs =" 0" maxOccurs =" unbounded" />
342
343
</xsd : sequence >
Original file line number Diff line number Diff line change @@ -104,25 +104,8 @@ protected static function createKernel(array $options = []): KernelInterface
104
104
{
105
105
static ::$ class ??= static ::getKernelClass ();
106
106
107
- if (isset ($ options ['environment ' ])) {
108
- $ env = $ options ['environment ' ];
109
- } elseif (isset ($ _ENV ['APP_ENV ' ])) {
110
- $ env = $ _ENV ['APP_ENV ' ];
111
- } elseif (isset ($ _SERVER ['APP_ENV ' ])) {
112
- $ env = $ _SERVER ['APP_ENV ' ];
113
- } else {
114
- $ env = 'test ' ;
115
- }
116
-
117
- if (isset ($ options ['debug ' ])) {
118
- $ debug = $ options ['debug ' ];
119
- } elseif (isset ($ _ENV ['APP_DEBUG ' ])) {
120
- $ debug = $ _ENV ['APP_DEBUG ' ];
121
- } elseif (isset ($ _SERVER ['APP_DEBUG ' ])) {
122
- $ debug = $ _SERVER ['APP_DEBUG ' ];
123
- } else {
124
- $ debug = true ;
125
- }
107
+ $ env = $ options ['environment ' ] ?? $ _ENV ['APP_ENV ' ] ?? $ _SERVER ['APP_ENV ' ] ?? 'test ' ;
108
+ $ debug = $ options ['debug ' ] ?? $ _ENV ['APP_DEBUG ' ] ?? $ _SERVER ['APP_DEBUG ' ] ?? true ;
126
109
127
110
return new static::$ class ($ env , $ debug );
128
111
}
You can’t perform that action at this time.
0 commit comments