diff --git a/src/main/java/org/olat/user/propertyhandlers/UserNameReadOnlyPropertyHandler.java b/src/main/java/org/olat/user/propertyhandlers/UserNameReadOnlyPropertyHandler.java index b97149f37fbddbba53d2330902a93e75fdb2a089..df749e2edff739f313478171c9a7588d696bc455 100644 --- a/src/main/java/org/olat/user/propertyhandlers/UserNameReadOnlyPropertyHandler.java +++ b/src/main/java/org/olat/user/propertyhandlers/UserNameReadOnlyPropertyHandler.java @@ -23,7 +23,6 @@ import java.util.Collections; import java.util.Locale; import java.util.Map; -import org.olat.basesecurity.BaseSecurityManager; import org.olat.core.gui.components.form.ValidationError; import org.olat.core.gui.components.form.flexible.FormItem; import org.olat.core.gui.components.form.flexible.FormItemContainer; @@ -47,16 +46,7 @@ import org.olat.user.UserImpl; * @author gnaegi, http://www.frentix.com */ public class UserNameReadOnlyPropertyHandler extends AbstractUserPropertyHandler { - private String authProvider; - /** - * Spring setter for the authentication provider - * @param authProvider - */ - public void setAuthProvider(String authProvider) { - this.authProvider = authProvider; - } - @Override public FormItem addFormItem(Locale locale, User user, String usageIdentifyer, boolean isAdministrativeUser, @@ -86,7 +76,7 @@ public class UserNameReadOnlyPropertyHandler extends AbstractUserPropertyHandler protected String getInternalValue(User user) { if (user instanceof UserImpl) { Identity identity = ((UserImpl)user).getIdentity(); - return BaseSecurityManager.getInstance().findAuthenticationName(identity, authProvider); + return identity.getName(); } return ""; } diff --git a/src/main/java/org/olat/user/propertyhandlers/_spring/userPropertriesHandlersContext.xml b/src/main/java/org/olat/user/propertyhandlers/_spring/userPropertriesHandlersContext.xml index 7e34d48fc7602ba9046dd4c58210efc68f47651e..2c9f20debdd013e17b3c8f7440242063f870b80b 100644 --- a/src/main/java/org/olat/user/propertyhandlers/_spring/userPropertriesHandlersContext.xml +++ b/src/main/java/org/olat/user/propertyhandlers/_spring/userPropertriesHandlersContext.xml @@ -13,7 +13,6 @@ <property name="name" value="userName" /> <property name="group" value="account" /> <property name="deletable" value="false" /> - <property name="authProvider" value="OLAT" /> <!-- could also be ldap, shibboleth, webdav, cal etc --> </bean> <bean id="userPropertyFirstName" class="org.olat.user.propertyhandlers.Generic127CharTextPropertyHandler">