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

Making e-mail restrictions case insensitive #9426

Merged
merged 2 commits into from Sep 14, 2018

Conversation

yshshrm
Copy link
Contributor

@yshshrm yshshrm commented Sep 14, 2018

Fixes #9425

I made the assumption that GUID will have ASCII values since the lower() function seems to break for some Greek characters.

@@ -87,7 +87,7 @@ def autocreate_username(candidate, tries=1):


def system_addon_submission_allowed(user, parsed_addon_data):
guid = parsed_addon_data.get('guid') or ''
guid = parsed_addon_data.get('guid').lower() or ''
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you make that parsed_addon_data.get('guid', '').lower() ? Need to handle the case where somehow guid is not present in parsed data (mainly for tests)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I realised that after seeing the failed tests.
Made a hotfix in a bit different way, is that one good or should I change to the method you mentioned?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect. Let's see if the tests pass now.

@diox diox merged commit 38490d3 into mozilla:master Sep 14, 2018
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

Successfully merging this pull request may close these issues.

None yet

2 participants