From b7a3a6b077c2b545f6793648ecadd63ebe247ac1 Mon Sep 17 00:00:00 2001 From: Adam Dobrawy Date: Tue, 15 May 2018 01:00:46 +0200 Subject: [PATCH] Fix Mailbox.get_connection --- django_mailbox/models.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/django_mailbox/models.py b/django_mailbox/models.py index 5c0e5af..49d0aad 100644 --- a/django_mailbox/models.py +++ b/django_mailbox/models.py @@ -224,7 +224,9 @@ class Mailbox(models.Model): conn = MHTransport(self.location) elif self.type == 'mmdf': conn = MMDFTransport(self.location) - return registry[self.type].from_url(self.uri) + else: + conn = registry[self.type].from_url(self.uri) + return conn def process_incoming_message(self, message): """Process a message incoming to this mailbox."""