mirror of
https://github.com/pacnpal/django-anymail.git
synced 2025-12-20 20:01:05 -05:00
Fix: Exception string whitespace and formatting
This commit is contained in:
@@ -31,8 +31,8 @@ class DjrillApiMixin(object):
|
|||||||
self.api_url = MANDRILL_API_URL
|
self.api_url = MANDRILL_API_URL
|
||||||
|
|
||||||
if not self.api_key:
|
if not self.api_key:
|
||||||
raise ImproperlyConfigured("You have not set your mandrill \
|
raise ImproperlyConfigured(
|
||||||
api key in the settings file.")
|
"You have not set your mandrill api key in the settings file.")
|
||||||
|
|
||||||
def get_context_data(self, **kwargs):
|
def get_context_data(self, **kwargs):
|
||||||
kwargs = super(DjrillApiMixin, self).get_context_data(**kwargs)
|
kwargs = super(DjrillApiMixin, self).get_context_data(**kwargs)
|
||||||
@@ -55,9 +55,9 @@ class DjrillApiJsonObjectsMixin(object):
|
|||||||
|
|
||||||
def get_api_uri(self):
|
def get_api_uri(self):
|
||||||
if self.api_uri is None:
|
if self.api_uri is None:
|
||||||
raise NotImplementedError("%(cls)s is missing an api_uri. Define \
|
raise NotImplementedError(
|
||||||
%(cls)s.api_uri or override \
|
"%(cls)s is missing an api_uri. "
|
||||||
%(cls)s.get_api_uri()." % {
|
"Define %(cls)s.api_uri or override %(cls)s.get_api_uri()." % {
|
||||||
"cls": self.__class__.__name__
|
"cls": self.__class__.__name__
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -93,7 +93,8 @@ class DjrillWebhookSecretMixin(object):
|
|||||||
if request.GET.get(secret_name) != secret:
|
if request.GET.get(secret_name) != secret:
|
||||||
return HttpResponse(status=403)
|
return HttpResponse(status=403)
|
||||||
|
|
||||||
return super(DjrillWebhookSecretMixin, self).dispatch(request, *args, **kwargs)
|
return super(DjrillWebhookSecretMixin, self).dispatch(
|
||||||
|
request, *args, **kwargs)
|
||||||
|
|
||||||
|
|
||||||
class DjrillIndexView(DjrillApiMixin, TemplateView):
|
class DjrillIndexView(DjrillApiMixin, TemplateView):
|
||||||
|
|||||||
Reference in New Issue
Block a user