Code Duplication    Length = 9-13 lines in 2 locations

src/Phinx/Db/Adapter/SQLiteAdapter.php 1 location

@@ 649-657 (lines=9) @@
646
        $columns = array_map('strtolower', $columns);
647
        $instructions = new AlterInstructions();
648
649
        foreach ($indexes as $index) {
650
            $a = array_diff($columns, $index['columns']);
651
            if (empty($a)) {
652
                $instructions->addPostStep(sprintf(
653
                    'DROP INDEX %s',
654
                    $this->quoteColumnName($index['index'])
655
                ));
656
            }
657
        }
658
659
        return $instructions;
660
    }

src/Phinx/Db/Adapter/OracleAdapter.php 1 location

@@ 562-574 (lines=13) @@
559
        $indexes = $this->getIndexes($tableName);
560
        $columns = array_map('strtoupper', $columns);
561
562
        foreach ($indexes as $indexName => $index) {
563
            $a = array_diff($columns, $index['columns']);
564
            if (empty($a)) {
565
                $this->execute(
566
                    sprintf(
567
                        'DROP INDEX %s',
568
                        $this->quoteColumnName($indexName)
569
                    )
570
                );
571
572
                break;
573
            }
574
        }
575
    }
576
577
    /**