Code Duplication    Length = 3-3 lines in 2 locations

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

@@ 361-363 (lines=3) @@
358
359
        $keys = array();
360
361
        foreach ($xmlIndex->{'key'} as $key) {
362
            $keys[(string) $key['name']] = isset($key['order']) ? (string) $key['order'] : 'asc';
363
        }
364
365
        $options = array();
366
@@ 469-471 (lines=3) @@
466
467
        $keys = array();
468
        $options = array();
469
        foreach ($xmlShardkey->{'key'} as $key) {
470
            $keys[(string) $key['name']] = isset($key['order']) ? (string)$key['order'] : 'asc';
471
        }
472
473
        if (isset($attributes['unique'])) {
474
            $options['unique'] = ('true' === (string) $attributes['unique']);