Code Duplication    Length = 5-5 lines in 2 locations

src/Admin/Traits/Mapper.php 2 locations

@@ 686-690 (lines=5) @@
683
                        $fields = [];
684
685
                        // takes the ordered fields
686
                        foreach ($blast[$class][ListMapper::class]['add']['_options']['fieldsOrder'] as $field) {
687
                            if (in_array($field, $tmp)) {
688
                                $fields[] = $field;
689
                            }
690
                        }
691
692
                        // then the forgotten fields as they come
693
                        foreach ($tmp as $field) {
@@ 693-697 (lines=5) @@
690
                        }
691
692
                        // then the forgotten fields as they come
693
                        foreach ($tmp as $field) {
694
                            if (!in_array($field, $blast[$class][ListMapper::class]['add']['_options']['fieldsOrder'])) {
695
                                $fields[] = $field;
696
                            }
697
                        }
698
                    }
699
                    $this->exportFields[$format] = $fields;
700
                }