Skip to content
This repository has been archived by the owner on Aug 2, 2019. It is now read-only.

Plugins loading #270

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions daybed/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
from pyramid.events import NewRequest
from pyramid.renderers import JSONP
from pyramid.authentication import BasicAuthAuthenticationPolicy
from pyramid.settings import aslist

from pyramid_hawkauth import HawkAuthenticationPolicy
from pyramid_multiauth import MultiAuthenticationPolicy
Expand Down Expand Up @@ -173,10 +174,10 @@ def attach_objects_to_request(event):
config.add_subscriber(attach_objects_to_request, NewRequest)

# Plugins
plugins = aslist(settings['daybed.plugins'])

try:
config.include("daybed_browserid")
except ImportError:
pass
for plugin in plugins:
print(plugin)
config.include(plugin)

return config.make_wsgi_app()