forked from mirror/django-mailbox
Modernize syntax, drop Python EOL, drop drop Django<1.11, upgrade TravisCI config to v1, add Python 3.8 & Django 3.x
This commit is contained in:
parent
f9b0a27e5f
commit
2b2b7d6392
43 changed files with 228 additions and 349 deletions
|
|
@ -1,5 +1,4 @@
|
|||
import sys
|
||||
import six
|
||||
|
||||
from .base import EmailTransport
|
||||
|
||||
|
|
@ -9,13 +8,8 @@ class GenericFileMailbox(EmailTransport):
|
|||
_path = None
|
||||
|
||||
def __init__(self, path):
|
||||
super(GenericFileMailbox, self).__init__()
|
||||
if six.PY2:
|
||||
self._path = path.encode(
|
||||
sys.getfilesystemencoding()
|
||||
)
|
||||
else:
|
||||
self._path = path
|
||||
super().__init__()
|
||||
self._path = path
|
||||
|
||||
def get_instance(self):
|
||||
return self._variant(self._path)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue