Remove leading/trailing whitespace from credit parts#1572
Merged
cpeel merged 1 commit intoDistributedProofreaders:masterfrom Apr 2, 2026
Merged
Remove leading/trailing whitespace from credit parts#1572cpeel merged 1 commit intoDistributedProofreaders:masterfrom
cpeel merged 1 commit intoDistributedProofreaders:masterfrom
Conversation
Ensure that all components used to build the credits field do not have leading or trailing whitespace. This could come from a user's real name field or "other" value, scanner credit, or extra credit.
srjfoo
approved these changes
Apr 2, 2026
Member
srjfoo
left a comment
There was a problem hiding this comment.
😁 -- this was challenging to test. What I wound up having to do ultimately was register a new TEST user with spaces trailing the real_name field. Updating your profile, you can't add trailing spaces to the real name, though you can to the credit name.
What turned out to be the challenge was that, as far as I could tell, the credit name field was already being trimmed. And the PPer field was already being trimmed. What wasn't being trimmed was the PM field.
To save others the trouble, compare the main test server with the sandbox
windymilla
approved these changes
Apr 2, 2026
Collaborator
windymilla
left a comment
There was a problem hiding this comment.
Thanks - that looks great!
chrismiceli
approved these changes
Apr 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Ensure that all components used to build the credits field do not have leading or trailing whitespace. This could come from a user's real name field or "other" value, scanner credit, or extra credit.
Note we don't have to do this for usernames as leading and trailing whitespace characters are not valid in usernames.
Fixes #1570
Sandbox: https://www.pgdp.org/~cpeel/c.branch/trim-credit-components/