Uniform settings handling

For MANDRILL_API_KEY (e.g.,), look for these settings:
* ANYMAIL = { 'MANDRILL_API_KEY': '...' }
* ANYMAIL_MANDRILL_API_KEY = "..."
* MANDRILL_API_KEY = "..."

(the "bare" third version is used only for settings that
might be reasonably shared with other apps, like api keys)
This commit is contained in:
medmunds
2016-03-04 17:02:43 -08:00
parent 3b414a9619
commit 38729df93c
7 changed files with 67 additions and 67 deletions

View File

@@ -1,4 +1,3 @@
from django.core.exceptions import ImproperlyConfigured
import json
from requests import HTTPError
@@ -68,10 +67,6 @@ class AnymailError(Exception):
return description
class AnymailImproperlyConfigured(AnymailError, ImproperlyConfigured):
"""Exception for configuration problems"""
class AnymailAPIError(AnymailError):
"""Exception for unsuccessful response from ESP's API."""