Code Duplication    Length = 3-3 lines in 2 locations

lib/Doctrine/ODM/MongoDB/Mapping/Driver/XmlDriver.php 2 locations

@@ 346-348 (lines=3) @@
343
344
        $keys = array();
345
346
        foreach ($xmlIndex->{'key'} as $key) {
347
            $keys[(string) $key['name']] = isset($key['order']) ? (string) $key['order'] : 'asc';
348
        }
349
350
        $options = array();
351
@@ 454-456 (lines=3) @@
451
452
        $keys = array();
453
        $options = array();
454
        foreach ($xmlShardkey->{'key'} as $key) {
455
            $keys[(string) $key['name']] = isset($key['order']) ? (string)$key['order'] : 'asc';
456
        }
457
458
        if (isset($attributes['unique'])) {
459
            $options['unique'] = ('true' === (string) $attributes['unique']);