Code Duplication    Length = 9-9 lines in 2 locations

src/ZohoDatabaseCopier.php 2 locations

@@ 161-169 (lines=9) @@
158
            $comparator = new \Doctrine\DBAL\Schema\Comparator();
159
            $tableDiff = $comparator->diffTable($dbTable, $table);
160
161
            if ($tableDiff !== false) {
162
                $diff = new SchemaDiff();
163
                $diff->fromSchema = $dbSchema;
164
                $diff->changedTables[$tableName] = $tableDiff;
165
                $statements = $diff->toSaveSql($this->connection->getDatabasePlatform());
166
                foreach ($statements as $sql) {
167
                    $this->connection->exec($sql);
168
                }
169
            }
170
        } else {
171
            $diff = new SchemaDiff();
172
            $diff->fromSchema = $dbSchema;
@@ 170-178 (lines=9) @@
167
                    $this->connection->exec($sql);
168
                }
169
            }
170
        } else {
171
            $diff = new SchemaDiff();
172
            $diff->fromSchema = $dbSchema;
173
            $diff->newTables[$tableName] = $table;
174
            $statements = $diff->toSaveSql($this->connection->getDatabasePlatform());
175
            foreach ($statements as $sql) {
176
                $this->connection->exec($sql);
177
            }
178
        }
179
    }
180
181
    /**