From 9393c4a6eb61bdceb393342e219b63d34a2d531c Mon Sep 17 00:00:00 2001 From: Panamus <7037867+Panamus@users.noreply.github.com> Date: Tue, 8 Jun 2021 12:01:15 +0100 Subject: [PATCH] fix: corrected typo in setting constant This corrects the subject typo from DEFAULT_SUJECT to DEFAULT_SUBJECT Fixes dipcode-software/django-cbmail#22 --- README.rst | 2 +- cbmail/base.py | 4 ++-- cbmail/conf.py | 2 +- runtests.py | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.rst b/README.rst index 57084e1..b72f1b3 100644 --- a/README.rst +++ b/README.rst @@ -58,7 +58,7 @@ settings: CBMAIL = { 'DEFAULT_REPLY_TO': "examplereplyto@example.com", - 'DEFAULT_SUJECT': "Example subject", + 'DEFAULT_SUBJECT': "Example subject", 'BASE_URL': "https://domain.com", 'EXTRA_DATA': {}, 'WHITELIST': [] diff --git a/cbmail/base.py b/cbmail/base.py index aa50dc8..bcb0d13 100644 --- a/cbmail/base.py +++ b/cbmail/base.py @@ -80,11 +80,11 @@ def get_mail_from(self): def get_subject(self): """ Returns the subject to be used on the subject email field - If one is not provided it will get the DEFAULT_SUJECT setting + If one is not provided it will get the DEFAULT_SUBJECT setting """ if self.subject: return self.subject - return settings.DEFAULT_SUJECT + return settings.DEFAULT_SUBJECT def get_template_name(self): """ Returns the template name to be used to render the email """ diff --git a/cbmail/conf.py b/cbmail/conf.py index 5df2289..867fe1f 100644 --- a/cbmail/conf.py +++ b/cbmail/conf.py @@ -9,7 +9,7 @@ DEFAULTS = { 'DEFAULT_REPLY_TO': 'examplereplyto@example.com', - 'DEFAULT_SUJECT': 'Example subject', + 'DEFAULT_SUBJECT': 'Example subject', 'BASE_URL': None, 'EXTRA_DATA': {}, 'WHITELIST': [] diff --git a/runtests.py b/runtests.py index a172355..29e19a8 100644 --- a/runtests.py +++ b/runtests.py @@ -12,7 +12,7 @@ ), CBMAIL={ 'DEFAULT_REPLY_TO': "replyto@unittest.com", - 'DEFAULT_SUJECT': "Unit test default", + 'DEFAULT_SUBJECT': "Unit test default", 'BASE_URL': "https://domain.com", }, DEFAULT_FROM_EMAIL="unit@unit.com",