Fixed py3 compat. (#1272)

* Fixed py3 compat.

see #1243

* Revert useless change.
This commit is contained in:
Antoine Nguyen
2017-10-11 17:46:17 +02:00
committed by GitHub
parent 32b2d17553
commit 8bce949b1d
@@ -82,8 +82,9 @@ class CheckMXRecords(BaseCommand):
"""Store DNSBL provider results for domain."""
alerts = {}
to_create = []
for mx in results.keys():
result = "" if not results[mx] else results[mx]
for mx, result in list(results.items()):
if not result:
result = ""
dnsbl_result = models.DNSBLResult.objects.filter(
domain=domain, provider=provider, mx=mx).first()
trigger = False