use of org.keycloak.storage.user.UserLookupProvider in project keycloak by keycloak.
the class UserStorageManager method getUserById.
/**
* {@link UserRegistrationProvider} methods implementations end here
* {@link UserLookupProvider} methods implementations start here
*/
@Override
public UserModel getUserById(RealmModel realm, String id) {
StorageId storageId = new StorageId(id);
if (storageId.getProviderId() == null) {
UserModel user = localStorage().getUserById(realm, id);
return importValidation(realm, user);
}
UserLookupProvider provider = getStorageProviderInstance(realm, storageId.getProviderId(), UserLookupProvider.class);
if (provider == null)
return null;
return provider.getUserById(realm, id);
}
Aggregations