)
def hooks(self):
- return [
+ hooks = [
('routes_mapping', Priority.NORMAL, add_routes_hook),
]
+
+ # frontpage plugin may or may not be installed
+ try:
+ from splinext.forum.frontpage_sources import ForumSource
+ hooks.append(
+ ('frontpage_updates_forum', Priority.NORMAL, ForumSource))
+ except ImportError:
+ pass
+
+ return hooks