When a user tries to add themselves as a contributor to a Work, sometimes their name(s) go into incorrect fields, and sometimes they fail to be added at all.
To Reproduce
Log in to HCommons (as Rand Test user, if possible)
Click on "Add a Work"
Click on "Contributors and Funding"
Click on "Add myself"
Possible failure states:
a. Nothing happens
b. User's full name is added to the surname(s) field and nothing appears in the first name(s) field
In case of 4b, save the contributor
Click on "Files" and upload a sample file
Click on "Save & Publish" and click the "Preview" button
Notice that the user's name is presented as undefined FULL_NAME
Expected behavior
User's surname, first name, affiliation (if present) and username should be correctly prefilled into the surname(s) and first name(s) fields.
The name should not contain "undefined" by default when presented on the preview page.
Describe the bug
When a user tries to add themselves as a contributor to a Work, sometimes their name(s) go into incorrect fields, and sometimes they fail to be added at all.
To Reproduce
undefined FULL_NAME
Expected behavior
User's surname, first name, affiliation (if present) and username should be correctly prefilled into the surname(s) and first name(s) fields.
The name should not contain "undefined" by default when presented on the preview page.
Additional context
See Issues #2 and #9 on the spreadsheet.
Screenshot