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

a bit improvements in the code #1

Merged
merged 2 commits into from Nov 25, 2021
Merged

a bit improvements in the code #1

merged 2 commits into from Nov 25, 2021

Conversation

signorrayan
Copy link
Contributor

@signorrayan signorrayan commented Nov 25, 2021

here are some thoughts about my pull request.

  1. It is better to create the hashes list before the for loop because the script does not operate on them, just checks for the existence of a value.
  2. When our referenced list elements are lowercase, key and key.lower() are the same and we don't need both of them.

It is better to create the hashes list before the for loop because the script does not operate on them, just checks for the existence of a value.
When our referenced list elements are lowercase, key and key.lower() are the same.
I didn't find lines 59 and 60 useful, because in line 57, the script checks whether the key exists in the list and the value never been empty. (Or perhaps you put them there for future options.)
@adulau
Copy link
Member

adulau commented Nov 25, 2021

Thank you for the pull-request.

@adulau adulau merged commit e548f9a into hashlookup:main Nov 25, 2021
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