summaryrefslogtreecommitdiff
path: root/Mailman/Gui/Topics.py
diff options
context:
space:
mode:
authormsapiro2006-07-07 17:55:47 +0000
committermsapiro2006-07-07 17:55:47 +0000
commit60b723291e592ff7925e1b15b79161d1cdac5938 (patch)
treee8354261d5e0ce32c365fbb14bbc388ad85f9664 /Mailman/Gui/Topics.py
parentc2f1602717fa63c5252a3178a6575c2ac943fbc5 (diff)
downloadmailman-60b723291e592ff7925e1b15b79161d1cdac5938.tar.gz
mailman-60b723291e592ff7925e1b15b79161d1cdac5938.tar.zst
mailman-60b723291e592ff7925e1b15b79161d1cdac5938.zip
Diffstat (limited to 'Mailman/Gui/Topics.py')
-rw-r--r--Mailman/Gui/Topics.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/Mailman/Gui/Topics.py b/Mailman/Gui/Topics.py
index 282930b7c..147b2de04 100644
--- a/Mailman/Gui/Topics.py
+++ b/Mailman/Gui/Topics.py
@@ -22,6 +22,8 @@ from Mailman import Utils
from Mailman.i18n import _
from Mailman.Gui.GUIBase import GUIBase
+OR = '|'
+
class Topics(GUIBase):
@@ -119,9 +121,10 @@ class Topics(GUIBase):
# Make sure the pattern was a legal regular expression
name = Utils.websafe(name)
try:
- re.compile(pattern)
+ orpattern = OR.join(pattern.splitlines())
+ re.compile(orpattern)
except (re.error, TypeError):
- safepattern = Utils.websafe(pattern)
+ safepattern = Utils.websafe(orpattern)
doc.addError(_("""The topic pattern '%(safepattern)s' is not a
legal regular expression. It will be discarded."""))
continue