Code Duplication    Length = 3-3 lines in 2 locations

lib/Doctrine/ODM/MongoDB/Mapping/Driver/XmlDriver.php 1 location

@@ 198-200 (lines=3) @@
195
        $class->mapField($mapping);
196
197
        // Index this field if either "index", "unique", or "sparse" are set
198
        if ( ! (isset($mapping['index']) || isset($mapping['unique']) || isset($mapping['sparse']))) {
199
            return;
200
        }
201
202
        $keys = array($name => $mapping['order'] ?? 'asc');
203
        $options = array();

lib/Doctrine/ODM/MongoDB/Mapping/Driver/YamlDriver.php 1 location

@@ 165-167 (lines=3) @@
162
163
        $class->mapField($mapping);
164
165
        if ( ! (isset($mapping['index']) || isset($mapping['unique']) || isset($mapping['sparse']))) {
166
            return;
167
        }
168
169
        // Multiple index specifications in one field mapping is ambiguous
170
        if ((isset($mapping['index']) && is_array($mapping['index'])) +