[ 
https://jira.duraspace.org/browse/DS-337?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=26927#comment-26927
 ] 

Bram Luyten (@mire) commented on DS-337:
----------------------------------------

I was wondering whether the trimming is already applied in all cases where 
eperson information is being set.

Given that some string processing (conversion to lower case) happens on the 
level of EPerson.java in the dspace-api, is there any reason why we're not 
trimming there?
https://github.com/DSpace/DSpace/blob/master/dspace-api/src/main/java/org/dspace/eperson/EPerson.java

I would suggest to add trimming in setEmail, setFirstName and setLastName

In JSPUI, it seems like there's no trimming in updateUserProfile (line 121)
https://github.com/DSpace/DSpace/blob/master/dspace-jspui/src/main/java/org/dspace/app/webui/servlet/EditProfileServlet.java

Any opinions?
                
> A bug related with adding new -EPersons
> ---------------------------------------
>
>                 Key: DS-337
>                 URL: https://jira.duraspace.org/browse/DS-337
>             Project: DSpace
>          Issue Type: Bug
>          Components: DSpace API
>            Reporter: Eija Airio
>            Assignee: Claudia Jürgen
>             Fix For: 1.6.0
>
>
> When the system admin is adding new E-Persons, and types a space character 
> after the email address, the space is stored to the email column in the 
> EPerson table as well. This naturally causes problems: for example the same 
> user is able to register with an email address without the space characters.
> This can be corrected by adding a trim funcion in 
> dspace-xmlui/dspace-xmlui-api/src/main/java/org/dspace/app/xmlui/aspect/administrative/FlowEPersonUtils.java:
> String email = (request.getParameter("email_address")).trim();

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Dspace-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-devel

Reply via email to