Hi. i'm working on some extensions for keycloak for our team purposes.
Today i note that some instance of GroupModel(retrieved from keycloak)
returned for me null from method getAttribute(String attrName). But
javadoc from GroupModel states that this method never return null:
/**
* @param name
* @return list of all attribute values or empty list if there are
not any values. Never return null
*/
List<String> getAttribute(String name);
I checked implementations in keycloak-parent and found this in
org.keycloak.models.cache.infinispan.GroupAdapter:
@Override
public List<String> getAttribute(String name) {
List<String> values = cached.getAttributes().get(name);
if (values == null) return null; <---- Attention
return values;
}
Is it bug?
Show replies by date