Last change
on this file since 1591 was
626,
checked in by crchemist, 18 years ago
|
Modified tests.
|
File size:
689 bytes
|
Line | |
---|
1 | from zope.interface import alsoProvides, noLongerProvides |
---|
2 | from zope.component import getUtility |
---|
3 | |
---|
4 | from interfaces import ISyndicationObject |
---|
5 | |
---|
6 | try: |
---|
7 | from vice.outbound.interfaces import IFeedConfigs |
---|
8 | success = True |
---|
9 | except ImportError: |
---|
10 | success = False |
---|
11 | |
---|
12 | def mark_syndication(object, event): |
---|
13 | if hasattr(object.aq_base, 'syndication_information') or \ |
---|
14 | (success and IFeedConfigs(object.aq_base, None)) and IFeedConfigs(object.aq_base).enabled: |
---|
15 | if not ISyndicationObject.providedBy(object): |
---|
16 | alsoProvides(object, ISyndicationObject) |
---|
17 | else: |
---|
18 | if ISyndicationObject.providedBy(object): |
---|
19 | noLongerProvides(object, ISyndicationObject) |
---|
Note: See
TracBrowser
for help on using the repository browser.