Redirect the user to the reverted change.

When the user reverts a change through the
use of the "Revert"-button, the user will get
redirected to the new change.

Change-Id: I6f3f616f67b8d53904968b17cdb96e6778b69475
This commit is contained in:
Gustaf Lundh
2011-10-27 11:52:32 -07:00
parent ac7d2f3448
commit 8f9b8f9714
3 changed files with 15 additions and 8 deletions

View File

@@ -256,7 +256,7 @@ public class ChangeUtil {
hooks.doChangeAbandonedHook(updatedChange, user.getAccount(), message);
}
public static void revert(final PatchSet.Id patchSetId,
public static Change.Id revert(final PatchSet.Id patchSetId,
final IdentifiedUser user, final String message, final ReviewDb db,
final RevertedSender.Factory revertedSenderFactory,
final ChangeHookRunner hooks, GitRepositoryManager gitManager,
@@ -352,6 +352,8 @@ public class ChangeUtil {
cm.send();
hooks.doPatchsetCreatedHook(change, ps);
return change.getId();
} finally {
revWalk.release();
git.close();