remove unnecessary discussion-check utility code.

svn path=/plone.app.discussion/trunk/; revision=29436
This commit is contained in:
Timo Stollenwerk 2009-08-28 13:34:45 +00:00
parent 96e2899955
commit a69f2baf01
2 changed files with 0 additions and 34 deletions

View File

@ -109,13 +109,4 @@
permission="cmf.ManagePortal"
/>
<!-- Utility view - use in portal_css or similar as portal/@@xdv-check/enabled" -->
<browser:page
name="discussion-check"
for="Products.CMFPlone.interfaces.IPloneSiteRoot"
class=".controlpanel.Utility"
permission="zope.Public"
allowed_attributes="globally_enabled"
/>
</configure>

View File

@ -40,28 +40,3 @@ class DiscussionSettingsEditForm(controlpanel.RegistryEditForm):
class DiscussionSettingsControlPanel(controlpanel.ControlPanelFormWrapper):
form = DiscussionSettingsEditForm
class Utility(BrowserView):
"""Utility view to determine ...
"""
def globally_enabled(self):
"""Determine if the utility is enabled and we are in an enabled domain
"""
registry = queryUtility(IRegistry)
if registry is None:
return False
settings = None
try:
settings = registry.forInterface(IDiscussionSettings)
except KeyError:
return False
if not settings.globally_enabled:
return False
else:
return True
return False