Code Duplication    Length = 7-7 lines in 2 locations

DependencyInjection/DoctrineExtension.php 2 locations

@@ 270-276 (lines=7) @@
267
                'mapping_types' => true,
268
                'platform_service' => true,
269
            ];
270
            foreach ($options as $key => $value) {
271
                if (isset($nonRewrittenKeys[$key])) {
272
                    continue;
273
                }
274
                $options['master'][$key] = $value;
275
                unset($options[$key]);
276
            }
277
            if (empty($options['wrapperClass'])) {
278
                // Change the wrapper class only if the user does not already forced using a custom one.
279
                $options['wrapperClass'] = 'Doctrine\\DBAL\\Connections\\MasterSlaveConnection';
@@ 305-311 (lines=7) @@
302
                'mapping_types' => true,
303
                'platform_service' => true,
304
            ];
305
            foreach ($options as $key => $value) {
306
                if (isset($nonRewrittenKeys[$key])) {
307
                    continue;
308
                }
309
                $options['global'][$key] = $value;
310
                unset($options[$key]);
311
            }
312
            if (empty($options['wrapperClass'])) {
313
                // Change the wrapper class only if the user does not already forced using a custom one.
314
                $options['wrapperClass'] = 'Doctrine\\DBAL\\Sharding\\PoolingShardConnection';