aboutsummaryrefslogtreecommitdiffstats
path: root/mediagoblin/app.py
diff options
context:
space:
mode:
authorChristopher Allan Webber <cwebber@dustycloud.org>2012-07-05 12:23:56 -0500
committerChristopher Allan Webber <cwebber@dustycloud.org>2012-07-14 12:55:13 -0500
commit3b47da8eab4ac8b4b580fb95da2d4a3e891e9555 (patch)
tree90f5569b9080101db1874338f71c490613ead923 /mediagoblin/app.py
parent828fc6300a5e9d1cf8cd10e875945ce7a8c3a1ab (diff)
downloadmediagoblin-3b47da8eab4ac8b4b580fb95da2d4a3e891e9555.tar.lz
mediagoblin-3b47da8eab4ac8b4b580fb95da2d4a3e891e9555.tar.xz
mediagoblin-3b47da8eab4ac8b4b580fb95da2d4a3e891e9555.zip
Themes are now registered and can have their templates loaded properly
Diffstat (limited to 'mediagoblin/app.py')
-rw-r--r--mediagoblin/app.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/mediagoblin/app.py b/mediagoblin/app.py
index 33acbba0..a10edfaa 100644
--- a/mediagoblin/app.py
+++ b/mediagoblin/app.py
@@ -76,10 +76,17 @@ class MediaGoblinApp(object):
# Register themes
self.theme_registry = register_themes(app_config)
+ self.current_theme_name = app_config.get('theme')
+ if self.current_theme_name \
+ and self.theme_registry.has_key(self.current_theme_name):
+ self.current_theme = self.theme_registry[self.current_theme_name]
+ else:
+ self.current_theme = None
# Get the template environment
self.template_loader = get_jinja_loader(
- app_config.get('local_templates'))
+ app_config.get('local_templates'),
+ self.current_theme)
# Set up storage systems
self.public_store, self.queue_store = setup_storage()