From 88b68f02f97fb90a2b9228c3861ad81dc1f37c60 Mon Sep 17 00:00:00 2001 From: Massimo DiPierro Date: Tue, 5 Jun 2012 18:08:01 -0500 Subject: [PATCH] issue 644, thanks Douglas and Alan --- VERSION | 2 +- gluon/dal.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/VERSION b/VERSION index 86fd44e8..95110752 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 2.00.0 (2012-06-05 18:00:56) dev +Version 2.00.0 (2012-06-05 18:07:58) dev diff --git a/gluon/dal.py b/gluon/dal.py index e314156c..469a0144 100644 --- a/gluon/dal.py +++ b/gluon/dal.py @@ -5330,7 +5330,7 @@ class IMAPAdapter(NoSQLAdapter): sub_items = [sub_item for sub_item in sub_items if len(sub_item.strip()) > 0] mailbox = sub_items[len(sub_items) - 1] # remove unwanted characters and store original names - mailbox_name = mailbox.replace("[", "").replace("]", "").replace("/", "_") + mailbox_name = re.sub('[^_\w]','',re.sub('[/ ]','_',mailbox)) mailboxes.append(mailbox_name) self.connection.mailbox_names[mailbox_name] = mailbox # print "Mailboxes query", mailboxes