diff pylons_app/config/environment.py @ 252:3782a6d698af

licensing updates, code cleanups
author Marcin Kuzminski <marcin@python-works.com>
date Fri, 04 Jun 2010 13:08:29 +0200
parents b18f89d6d17f
children 0e5455fda8fd
line wrap: on
line diff
--- a/pylons_app/config/environment.py	Fri Jun 04 11:29:05 2010 +0200
+++ b/pylons_app/config/environment.py	Fri Jun 04 13:08:29 2010 +0200
@@ -4,6 +4,7 @@
 from pylons.error import handle_mako_error
 from pylons_app.config.routing import make_map
 from pylons_app.lib.auth import set_available_permissions
+from pylons_app.lib.utils import repo2db_mapper
 from pylons_app.model import init_model
 from sqlalchemy import engine_from_config
 import logging
@@ -11,8 +12,6 @@
 import pylons_app.lib.app_globals as app_globals
 import pylons_app.lib.helpers
 
-
-
 log = logging.getLogger(__name__)
 
 def load_environment(global_conf, app_conf):
@@ -39,7 +38,6 @@
     import pylons
     pylons.cache._push_object(config['pylons.app_globals'].cache)
     
-
     # Create the Mako TemplateLookup, with the default auto-escaping
     config['pylons.app_globals'].mako_lookup = TemplateLookup(
         directories=paths['templates'],
@@ -48,7 +46,7 @@
         input_encoding='utf-8', default_filters=['escape'],
         imports=['from webhelpers.html import escape'])
 
-    #sets the c attribute access when don't existing attribute ar accessed
+    #sets the c attribute access when don't existing attribute are accessed
     config['pylons.strict_tmpl_context'] = True
     
     #MULTIPLE DB configs
@@ -62,7 +60,7 @@
         sa_engine_db1 = engine_from_config(config, 'sqlalchemy.db1.')
 
     init_model(sa_engine_db1)
-
+    repo2db_mapper()
     set_available_permissions(config)
     # CONFIGURATION OPTIONS HERE (note: all config options will override
     # any Pylons config options)