Gerrit: Do not pass username for anonymous access

Change-Id: Idaa04d359ac36d8265d34feb725da54e30392788
Reviewed-by: André Hartmann <aha_1980@gmx.de>
This commit is contained in:
Orgad Shaneh
2017-03-06 08:20:07 +02:00
committed by Orgad Shaneh
parent ea8ff05952
commit 1c3b11ed54

View File

@@ -149,7 +149,9 @@ GerritParameters::GerritParameters()
QString GerritServer::hostArgument() const QString GerritServer::hostArgument() const
{ {
return user.userName.isEmpty() ? host : (user.userName + '@' + host); if (!authenticated || user.userName.isEmpty())
return host;
return user.userName + '@' + host;
} }
QString GerritServer::url(UrlType urlType) const QString GerritServer::url(UrlType urlType) const