moksha/wsgiapp.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
New commits:
commit 0b5c8294f67e358d0352fa1f1515c111271d46dd
Author: Luke Macken <lmacken(a)redhat.com>
Date: Wed Apr 15 10:02:10 2009 -0400
Prevent the RootController from being imported before our application and
configuration are loaded
diff --git a/moksha/wsgiapp.py b/moksha/wsgiapp.py
index 82e6fe9..f8184b6 100644
--- a/moksha/wsgiapp.py
+++ b/moksha/wsgiapp.py
@@ -17,7 +17,6 @@
# Authors: Luke Macken <lmacken(a)redhat.com>
from pylons.wsgiapp import PylonsApp
-from moksha.controllers.root import RootController
class MokshaAppDispatcher(PylonsApp):
""" Moksha WSGI Application Dispatcher.
@@ -30,6 +29,8 @@ class MokshaAppDispatcher(PylonsApp):
def __init__(self):
super(MokshaAppDispatcher, self).__init__()
+ from moksha.controllers.root import RootController
+ self.root = RootController
def resolve(self, environ, start_response):
""" Uses dispatching information found in
@@ -39,4 +40,4 @@ class MokshaAppDispatcher(PylonsApp):
"""
environ['pylons.routes_dict'] =
environ['wsgiorg.routing_args'][1]
- return RootController()
+ return self.root()
Show replies by date