Added important comment

This commit is contained in:
Luca Frosini 2021-12-01 11:51:45 +01:00
parent a8c35a17e4
commit 4af598dfa8
1 changed files with 10 additions and 4 deletions

View File

@ -70,14 +70,20 @@ public class SecretManager {
setAll(secretHolder.getAuthorizationSecrets());
}
private void setAll(SortedSet<Secret> authorizationSecrets) throws Exception {
private void setAll(SortedSet<Secret> secrets) throws Exception {
boolean first = true;
for(Secret authorizationSecret : authorizationSecrets) {
for(Secret secret : secrets) {
/*
* Only the most important Secret must set
* AuthorizationProvider and ScopeProvider
* the others just need to set their token
* in the correspondent provider
*/
if(first) {
authorizationSecret.set();
secret.set();
first = false;
}else {
authorizationSecret.setToken();
secret.setToken();
}
}
}