diff options
author | Dave Borowitz <dborowitz@google.com> | 2018-02-21 09:36:09 -0500 |
---|---|---|
committer | David Ostrovsky <david@ostrovsky.org> | 2018-02-21 17:56:30 +0100 |
commit | aa8bea6d8d3dcdaa313a15a1f41b6c14a426cc77 (patch) | |
tree | bb3d5f69f29d7b72d3a471cd369347bd6163182c | |
parent | ff03f0b455b3ebee817cb0599850c04c30327665 (diff) |
Change default of migrating draft changes to WIP, not private
Consensus on Issue 8346 is that this more closely matches user
expectations, even though it is a less paranoid default. Administrators
who are paranoid about the possibility of leaking draft patch sets are
still prompted during the schema upgrade.
Bug: Issue 8346
Change-Id: I53e4b8c4de3dd2f169853858ee3ee7eca045cdb4
-rw-r--r-- | gerrit-server/src/main/java/com/google/gerrit/server/schema/Schema_159.java | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/gerrit-server/src/main/java/com/google/gerrit/server/schema/Schema_159.java b/gerrit-server/src/main/java/com/google/gerrit/server/schema/Schema_159.java index 3bb0e98b17..67cba36cd6 100644 --- a/gerrit-server/src/main/java/com/google/gerrit/server/schema/Schema_159.java +++ b/gerrit-server/src/main/java/com/google/gerrit/server/schema/Schema_159.java @@ -35,10 +35,9 @@ public class Schema_159 extends SchemaVersion { @Override protected void migrateData(ReviewDb db, UpdateUI ui) throws OrmException { - DraftWorkflowMigrationStrategy strategy = DraftWorkflowMigrationStrategy.PRIVATE; - if (ui.yesno( - false, "Migrate draft changes to work-in-progress changes (default is private)?")) { - strategy = DraftWorkflowMigrationStrategy.WORK_IN_PROGRESS; + DraftWorkflowMigrationStrategy strategy = DraftWorkflowMigrationStrategy.WORK_IN_PROGRESS; + if (ui.yesno(false, "Migrate draft changes to private changes (default is work-in-progress)")) { + strategy = DraftWorkflowMigrationStrategy.PRIVATE; } ui.message( String.format("Replace draft changes with %s changes ...", strategy.name().toLowerCase())); |