summaryrefslogtreecommitdiff
path: root/src/mailman/styles/manager.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/mailman/styles/manager.py')
-rw-r--r--src/mailman/styles/manager.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mailman/styles/manager.py b/src/mailman/styles/manager.py
index cf3d07711..e9682d7c5 100644
--- a/src/mailman/styles/manager.py
+++ b/src/mailman/styles/manager.py
@@ -52,9 +52,9 @@ class StyleManager:
# Install all the styles described by the configuration files.
for section in config.style_configs:
class_path = section['class']
- module_name, class_name = class_path.rsplit('.', 1)
- __import__(module_name)
- style = getattr(sys.modules[module_name], class_name)()
+ package, dot, class_name = class_path.rpartition('.')
+ __import__(package)
+ style = getattr(sys.modules[package], class_name)()
assert section.name.startswith('style'), (
'Bad style section name: %s' % section.name)
style.name = section.name[6:]