Permalink
Browse files

Remove unused `sender` from batch mailer.

The batch mailer doesn't use the `sender` property, so no need to pass
it in as a kwarg or do the complicated `_PMBatchMail__sender` dance.
  • Loading branch information...
1 parent 4c53292 commit 0b403411954affc325b7bfa9516ed496af41e2d1 @thruflo thruflo committed Jun 18, 2012
Showing with 0 additions and 16 deletions.
  1. +0 −16 postmark/core.py
View
@@ -451,12 +451,10 @@ class PMBatchMail(object):
def __init__(self, **kwargs):
self.__api_key = None
- self.__sender = None
self.__messages = []
acceptable_keys = (
'api_key',
- 'sender',
'messages'
)
@@ -474,8 +472,6 @@ def __init__(self, **kwargs):
self.__user_agent = '%s (Django %s)' % (self.__user_agent, '_'.join([str(var) for var in VERSION]))
if not self.__api_key and hasattr(django_settings, 'POSTMARK_API_KEY'):
self.__api_key = django_settings.POSTMARK_API_KEY
- if not self.__sender and hasattr(django_settings, 'POSTMARK_SENDER'):
- self.__sender = django_settings.POSTMARK_SENDER
except ImportError:
pass
@@ -488,18 +484,6 @@ def __init__(self, **kwargs):
'''
)
- sender = property(
- lambda self: self.__sender,
- lambda self, value: setattr(self, '_PMMail__sender', value),
- lambda self: setattr(self, '_PMMail__sender', None),
- '''
- The sender, in either "name@email.com" or "First Last <name@email.com>" formats.
- The address should match one of your Sender Signatures in Postmark.
- Specifying the address in the second fashion will allow you to replace
- the name of the sender as it appears in the recipient's email client.
- '''
- )
-
messages = property(
lambda self: self.__messages,
lambda self, value: setattr(self, '_PMMail__messages', value),

0 comments on commit 0b40341

Please sign in to comment.