Code Duplication    Length = 6-6 lines in 2 locations

src/Formatter.php 2 locations

@@ 379-384 (lines=6) @@
376
            $subKey = $parts[0];
377
        }
378
379
        if ($this->isIdentifierField($subKey)) {
380
            // Handle like a regular relationship
381
            list($key, $value) = $this->formatQueryElementRel($root, $value, $metadata, $store);
382
            $key = (true === $hasIndex) ? sprintf('%s.%s', $key, $parts[0]) : $key;
383
            return [$key, $value];
384
        }
385
386
        if ($this->isTypeField($subKey)) {
387
            // Handle as a model type field.
@@ 386-391 (lines=6) @@
383
            return [$key, $value];
384
        }
385
386
        if ($this->isTypeField($subKey)) {
387
            // Handle as a model type field.
388
            list($key, $value) = $this->formatQueryElementRoot($subKey, $value, $metadata);
389
            $key = (true === $hasIndex) ? sprintf('%s.%s.%s', $root, $parts[0], $key) : sprintf('%s.%s', $root, $key);
390
            return [$key, $value];
391
        }
392
        return [$key, $value];
393
    }
394