Skip to content

Commit

Permalink
Merge pull request #881 from plone/fix-site-root-syndication
Browse files Browse the repository at this point in the history
Do not throw a 404 on site root RSS feeds
  • Loading branch information
hvelarde committed Sep 8, 2015
2 parents 53e5390 + f25e125 commit 859b9a0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Products/CMFPlone/browser/syndication/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ def feed(self):
def __call__(self):
util = getMultiAdapter((self.context, self.request),
name='syndication-util')
if util.context_enabled(raise404=True):
context_state = getMultiAdapter((self.context, self.request),
name=u'plone_context_state')
if context_state.is_portal_root() or util.context_enabled(raise404=True):
settings = IFeedSettings(self.context)
if self.__name__ not in settings.feed_types:
raise NotFound
Expand Down Expand Up @@ -111,8 +113,9 @@ def __call__(self):

class SettingsForm(form.EditForm):
label = _(u'heading_syndication_properties',
default=u'Syndication Properties')
description = _(u'description_syndication_properties',
default=u'Syndication Properties')
description = _(
u'description_syndication_properties',
default=u'Syndication enables you to syndicate this folder so it can'
u'be synchronized from other web sites.')
fields = field.Fields(IFeedSettings)
Expand Down
3 changes: 3 additions & 0 deletions docs/CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ Changelog
4.3.7 (unreleased)
------------------

- Do not throw a 404 on site root RSS feeds
[vangheem]

- Upgrade known core packages at the end of the Plone migration.
[maurits]

Expand Down

0 comments on commit 859b9a0

Please sign in to comment.