Fix ChainingCredentialsProvider
The ChainingCredentialsProvider gave up chaining to the next provider if the first one returned no credentials items for the given URI. Change-Id: I9539c50db35e564db9d43d8ebb71d7e9c6fdcc19 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
This commit is contained in:
parent
ac89b47eeb
commit
5786cc3c0f
|
@ -113,9 +113,15 @@ public boolean get(URIish uri, CredentialItem... items)
|
|||
throws UnsupportedCredentialItem {
|
||||
for (CredentialsProvider p : credentialProviders) {
|
||||
if (p.supports(items)) {
|
||||
p.get(uri, items);
|
||||
if (isAnyNull(items))
|
||||
if (!p.get(uri, items)) {
|
||||
if (p.isInteractive()) {
|
||||
return false; // user cancelled the request
|
||||
}
|
||||
continue;
|
||||
}
|
||||
if (isAnyNull(items)) {
|
||||
continue;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue