Skip to content

Conversation

adamspd
Copy link
Owner

@adamspd adamspd commented Aug 19, 2024

Enhance staff member name retrieval with additional fallbacks

When choosing a staff member, the name retrieval process follows these steps:

  1. Get full name
  2. If empty, get username
  3. If username empty, get email (new)
  4. If email is empty too, return "Staff Member {id}" (new)

This pull request adds steps 3 and 4 to provide better fallbacks when limited user information is available.

Note: The correct practice when adding a staff member is to include all relevant user information. These fallbacks are implemented to handle edge cases and ensure a meaningful identifier is always returned.

See issue #237

@adamspd adamspd linked an issue Aug 19, 2024 that may be closed by this pull request
4 tasks
@adamspd adamspd self-assigned this Aug 19, 2024
@github-actions github-actions bot added the tests label Aug 19, 2024
@adamspd adamspd added the enhancement New feature or request label Aug 19, 2024
@adamspd adamspd merged commit 14494e4 into main Aug 19, 2024
@adamspd adamspd deleted the 237-staff-shows-none-none-not-showing-email branch August 19, 2024 09:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Staff shows None None not showing email
1 participant