From e621900de98ed147d95512e27b842b000083cb30 Mon Sep 17 00:00:00 2001 From: Robin Bygrave Date: Sun, 31 Jul 2016 23:23:43 +1200 Subject: [PATCH] #794 - Refactor - tidy code, remove unused method arguments --- .../java/com/avaje/ebean/dbmigration/model/MTable.java | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/avaje/ebean/dbmigration/model/MTable.java b/src/main/java/com/avaje/ebean/dbmigration/model/MTable.java index 8e8610751..e7e8c66f6 100644 --- a/src/main/java/com/avaje/ebean/dbmigration/model/MTable.java +++ b/src/main/java/com/avaje/ebean/dbmigration/model/MTable.java @@ -270,17 +270,15 @@ public class MTable { } // compare existing columns (look for dropped columns) - int columnPosition = 0; for (MColumn existingColumn : allColumns()) { MColumn newColumn = newColumnMap.get(existingColumn.getName()); if (newColumn == null) { - diffDropColumn(modelDiff, existingColumn, columnPosition, newTable); + diffDropColumn(modelDiff, existingColumn); } else if (newColumn.isDraftOnly() && !draft) { // effectively a drop column (draft only column on a non-draft table) logger.trace("... drop column {} from table {} as now draftOnly", newColumn.getName(), name); - diffDropColumn(modelDiff, existingColumn, columnPosition, newTable); + diffDropColumn(modelDiff, existingColumn); } - columnPosition++; } if (addColumn != null) { @@ -540,7 +538,7 @@ public class MTable { /** * Add a 'drop column' to the diff. */ - private void diffDropColumn(ModelDiff modelDiff, MColumn existingColumn, int columnPosition, MTable newTable) { + private void diffDropColumn(ModelDiff modelDiff, MColumn existingColumn) { DropColumn dropColumn = new DropColumn(); dropColumn.setTableName(name);