Code Duplication    Length = 5-6 lines in 2 locations

code/DataIntegrityMoveFieldUpOrDownClassHierarchy.php 2 locations

@@ 196-201 (lines=6) @@
193
                                );
194
                                $modelFields1 + $hasOneArray;
195
                                //$modelFields1 = array_keys((array)Injector::inst()->get($testTable1)->db()) + array_keys((array)Injector::inst()->get($testTable1)->has_one());
196
                                foreach ($interSect as $moveableField) {
197
                                    if (in_array($moveableField, $modelFields1)) {
198
                                        $link["movetoparent"][$moveableField] = "<a href=\"".$this->Link()."?oldtable=$testTable2&newtable=$testTable1&field=$moveableField\">move from $testTable2 into $testTable1</a>";
199
                                        ;
200
                                    }
201
                                }
202
                            }
203
                            $link["movetochild"] = array();
204
                            if (in_array("DataObject", $parentArray1)) {
@@ 215-219 (lines=5) @@
212
                                );
213
                                $modelFields2 + $hasOneArray;
214
                                //$modelFields2 = array_keys((array)Injector::inst()->get($testTable2)->db()) + array_keys((array)Injector::inst()->get($testTable2)->has_one());
215
                                foreach ($interSect as $moveableField) {
216
                                    if (in_array($moveableField, $modelFields2)) {
217
                                        $link["movetochild"][$moveableField] = "<a href=\"".$this->Link()."?oldtable=$testTable1&newtable=$testTable2&field=$moveableField\">move from $testTable1  into $testTable2</a>";
218
                                    }
219
                                }
220
                            }
221
                            $str = "$testTable1 &lt;&gt; $testTable2<br /><ul>";
222
                            foreach ($interSect as $moveableField) {