formatting
This commit is contained in:
@@ -346,10 +346,8 @@ public class ConfigClientProperties {
|
||||
result.username = explicitCredentials.username;
|
||||
}
|
||||
|
||||
result.password = URLDecoder.decode(result.password,
|
||||
StandardCharsets.UTF_8.toString());
|
||||
result.username = URLDecoder.decode(result.username,
|
||||
StandardCharsets.UTF_8.toString());
|
||||
result.password = URLDecoder.decode(result.password, StandardCharsets.UTF_8.toString());
|
||||
result.username = URLDecoder.decode(result.username, StandardCharsets.UTF_8.toString());
|
||||
return result;
|
||||
}
|
||||
catch (MalformedURLException | UnsupportedEncodingException e) {
|
||||
|
||||
@@ -96,8 +96,7 @@ public class GitCredentialsProviderFactory {
|
||||
// useful for token based login gh-1602
|
||||
// see
|
||||
// https://stackoverflow.com/questions/28073266/how-to-use-jgit-to-push-changes-to-remote-with-oauth-access-token
|
||||
this.logger.debug(
|
||||
"Constructing UsernamePasswordCredentialsProvider for URI " + uri);
|
||||
this.logger.debug("Constructing UsernamePasswordCredentialsProvider for URI " + uri);
|
||||
provider = new UsernamePasswordCredentialsProvider(username, (String) null);
|
||||
}
|
||||
else if (hasText(passphrase)) {
|
||||
|
||||
@@ -68,8 +68,7 @@ public class GitCredentialsProviderFactoryTests {
|
||||
|
||||
@Test
|
||||
public void testCreateForServerWithUsernameAndNoPassword() {
|
||||
CredentialsProvider provider = this.factory.createFor(HTTPS_GIT_REPO, USER, "",
|
||||
null, false);
|
||||
CredentialsProvider provider = this.factory.createFor(HTTPS_GIT_REPO, USER, "", null, false);
|
||||
assertThat(provider).isNotNull();
|
||||
assertThat(provider instanceof UsernamePasswordCredentialsProvider).isTrue();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user