main: make ruff default rules happy
This commit is contained in:
parent
8c5a6854e6
commit
deb69ca69f
@ -58,14 +58,14 @@ def sanitize_name(self, name):
|
||||
valid characters and finally trims all excess whitespace"""
|
||||
|
||||
# Some submissions contain no alphabetic characters, skip them
|
||||
if all(not l.isalpha() for l in name):
|
||||
if all(not l.isalpha() for l in name): # noqa: E741
|
||||
return u''
|
||||
|
||||
# Strip any numbers, they could be a bank account number
|
||||
name = u''.join([l for l in name if not l.isdigit()])
|
||||
name = u''.join([l for l in name if not l.isdigit()]) # noqa: E741
|
||||
|
||||
# Normalize all capitalized names. (JOHN DOE)
|
||||
name = u' '.join(l.capitalize() for l in name.split(u' '))
|
||||
name = u' '.join(l.capitalize() for l in name.split(u' ')) # noqa: E741
|
||||
|
||||
# Trim excess spaces
|
||||
name = name.rstrip().lstrip()
|
||||
|
@ -59,7 +59,7 @@ def empty_response():
|
||||
|
||||
|
||||
# utility to make a pair of django choices
|
||||
make_choice = lambda l: [(str(m), str(m)) for m in l]
|
||||
make_choice = lambda l: [(str(m), str(m)) for m in l] # noqa E741
|
||||
|
||||
|
||||
def set_created_field(sender, **kwargs):
|
||||
|
Loading…
Reference in New Issue
Block a user