From c6466868d8a60ffa40fb85517e789b7995f3ac1c Mon Sep 17 00:00:00 2001 From: Daniel Welch Date: Thu, 7 Dec 2017 18:30:54 -0500 Subject: [PATCH] fix usage of iter_entry_points --- django_q/conf.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/django_q/conf.py b/django_q/conf.py index 2bb6c98..6e955a1 100644 --- a/django_q/conf.py +++ b/django_q/conf.py @@ -216,10 +216,10 @@ if Conf.ERROR_REPORTER: # iterate through the configured error reporters, # and instantiate an ErrorReporter using the provided config for name, conf in error_conf.items(): - Reporter = pkg_resources.iter_entry_points( - 'djangoq.errorreporters', name).load() - e = Reporter(**conf) - reporters.append(e) + for entry in pkg_resources.iter_entry_points( + 'djangoq.errorreporters', name): + Reporter = entry.load() + reporters.append(Reporter(**conf)) error_reporter = ErrorReporter(reporters) except ImportError: error_reporter = None