CamelCase to snake_case

This commit is contained in:
Adrià Casajús 2022-03-21 17:59:43 +01:00
parent 45459d65be
commit 5f831d593a
No known key found for this signature in database
GPG key ID: F0033226A5AFC9B9

View file

@ -1440,10 +1440,10 @@ def get_dmarc_status(msg: Message) -> Optional[DmarcCheckResult]:
if not spam_result: if not spam_result:
return None return None
spam_entries = [entry.strip() for entry in spam_result[-1].split("\n")] spam_entries = [entry.strip() for entry in spam_result[-1].split("\n")]
for iPos in range(len(spam_entries)): for entry_pos in range(len(spam_entries)):
sep = spam_entries[iPos].find("(") sep = spam_entries[entry_pos].find("(")
if sep > -1: if sep > -1:
spam_entries[iPos] = spam_entries[iPos][:sep] spam_entries[entry_pos] = spam_entries[entry_pos][:sep]
for header_value, dmarc_result in DmarcCheckResult.get_string_dict().items(): for header_value, dmarc_result in DmarcCheckResult.get_string_dict().items():
if header_value in spam_entries: if header_value in spam_entries:
return dmarc_result return dmarc_result