Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

display_name isn't saved after refresh #1306

Open
dnoneill opened this issue Aug 29, 2024 · 3 comments
Open

display_name isn't saved after refresh #1306

dnoneill opened this issue Aug 29, 2024 · 3 comments

Comments

@dnoneill
Copy link
Contributor

When the user logs in, immediately after their display name is displayed. However after you navigate away or refresh the page, the app loses the variable.
Screenshot 2024-08-29 at 2 48 58 PM
Screenshot 2024-08-29 at 2 48 42 PM

@jcoyne
Copy link
Contributor

jcoyne commented Aug 30, 2024

@dnoneill This is because the second time, they have a earthworks cookie an they don't need to log in with SAML. The display name must be cached (probably in the Users table).

@jcoyne
Copy link
Contributor

jcoyne commented Aug 30, 2024

If you use https://github.com/duke-libraries/devise-remote-user then set attribute_map See https://github.com/sul-dlss/happy-heron/blob/8a1eae6571f68f61150c06ca2e35ac64393bace3/config/initializers/devise_remote_user.rb#L16

config.attribute_map = { shibboleth_groups: 'eduPersonEntitlement', display_name: 'displayName' }

@jcoyne
Copy link
Contributor

jcoyne commented Aug 30, 2024

Hmm, looks like all that is configured as expected.

@dnoneill dnoneill assigned dnoneill and unassigned dnoneill Sep 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants