Store licensing info as well
authorChristopher Allan Webber <cwebber@dustycloud.org>
Sun, 15 Jul 2012 01:23:21 +0000 (20:23 -0500)
committerChristopher Allan Webber <cwebber@dustycloud.org>
Sun, 15 Jul 2012 01:23:21 +0000 (20:23 -0500)
mediagoblin/tools/theme.py

index b19b16df2679d911e08270f4ce61e027412ce654..4c7a7c0e693706a5047e6b45274ddeff89a1a00a 100644 (file)
@@ -32,7 +32,7 @@ def themedata_for_theme_dir(name, theme_dir):
     Given a theme directory, extract important theme information.
     """
     # open config
-    config = ConfigObj(os.path.join(theme_dir, 'theme.ini'))
+    config = ConfigObj(os.path.join(theme_dir, 'theme.ini')).get('theme')
 
     templates_dir = os.path.join(theme_dir, 'templates')
     if not os.path.exists(templates_dir):
@@ -45,6 +45,7 @@ def themedata_for_theme_dir(name, theme_dir):
     themedata = {
         'name': config.get('name', name),
         'description': config.get('description'),
+        'licensing': config.get('licensing'),
         'dir': theme_dir,
         'templates_dir': templates_dir,
         'assets_dir': assets_dir,