summaryrefslogtreecommitdiff
path: root/src/mailman/rest/root.py
diff options
context:
space:
mode:
authorBarry Warsaw2014-08-13 12:55:24 -0400
committerBarry Warsaw2014-08-13 12:55:24 -0400
commit5be40dfb86ceaed9a47e1efff108fdeaf7a568fd (patch)
tree0acd2d883e20b8f0cd712499c993f5a4eb1ed1d7 /src/mailman/rest/root.py
parent45691d23d4fb4dca8e7a3d7442186a333e7f9663 (diff)
downloadmailman-5be40dfb86ceaed9a47e1efff108fdeaf7a568fd.tar.gz
mailman-5be40dfb86ceaed9a47e1efff108fdeaf7a568fd.tar.zst
mailman-5be40dfb86ceaed9a47e1efff108fdeaf7a568fd.zip
Diffstat (limited to 'src/mailman/rest/root.py')
-rw-r--r--src/mailman/rest/root.py9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/mailman/rest/root.py b/src/mailman/rest/root.py
index 9e9f5bfa5..c8dce0eca 100644
--- a/src/mailman/rest/root.py
+++ b/src/mailman/rest/root.py
@@ -35,11 +35,10 @@ from mailman.config import config
from mailman.core.constants import system_preferences
from mailman.core.system import system
from mailman.interfaces.listmanager import IListManager
-from mailman.interfaces.styles import IStyleManager
from mailman.rest.addresses import AllAddresses, AnAddress
from mailman.rest.domains import ADomain, AllDomains
from mailman.rest.helpers import BadRequest, NotFound, child, etag, path_to
-from mailman.rest.lists import AList, AllLists
+from mailman.rest.lists import AList, AllLists, Styles
from mailman.rest.members import AMember, AllMembers, FindMembers
from mailman.rest.preferences import ReadOnlyPreferences
from mailman.rest.templates import TemplateFinder
@@ -139,11 +138,7 @@ class TopLevel:
if len(segments) == 0:
return AllLists()
elif len(segments) == 1 and segments[0] == 'styles':
- manager = getUtility(IStyleManager)
- style_names = sorted(style.name for style in manager.styles)
- resource = dict(style_names=style_names,
- default=config.styles.default)
- return http.ok([], etag(resource))
+ return Styles(), []
else:
# list-id is preferred, but for backward compatibility,
# fqdn_listname is also accepted.