Fix double slash on URL when switching account.

One too many ending forward slashes causes OpenIdService to
redirect url to http://localhost:8080//

Remove the extra slash on switch account.

Bug: Issue 3664
Change-Id: I7fc66aaacc0c2f49a837222b2c2cf67a84ac967d
This commit is contained in:
David Ostrovsky 2015-11-10 16:06:30 -08:00 committed by David Pursehouse
parent cf75006b10
commit 08f1cfa977

View File

@ -55,7 +55,7 @@ public class UserPopupPanel extends PopupPanel {
switchAccount.setHref(Gerrit.getConfig().getSwitchAccountUrl()); switchAccount.setHref(Gerrit.getConfig().getSwitchAccountUrl());
} else if (Gerrit.getConfig().getAuthType() == AuthType.DEVELOPMENT_BECOME_ANY_ACCOUNT } else if (Gerrit.getConfig().getAuthType() == AuthType.DEVELOPMENT_BECOME_ANY_ACCOUNT
|| Gerrit.getConfig().getAuthType() == AuthType.OPENID) { || Gerrit.getConfig().getAuthType() == AuthType.OPENID) {
switchAccount.setHref(Gerrit.selfRedirect("/login/")); switchAccount.setHref(Gerrit.selfRedirect("/login"));
} else { } else {
switchAccount.removeFromParent(); switchAccount.removeFromParent();
switchAccount = null; switchAccount = null;