Loading text theme tidy up
authorDarren <darren@darrenwhitlen.com>
Wed, 7 May 2014 23:38:03 +0000 (00:38 +0100)
committerDarren <darren@darrenwhitlen.com>
Wed, 7 May 2014 23:38:03 +0000 (00:38 +0100)
client/src/app.js
client/src/index.html.tmpl

index 39121b2f4cf84e6a83faf08c8b6b5dc8c8c0dff4..861b8f1f05d21fd825a8c95f270bc648494e18f8 100644 (file)
@@ -158,12 +158,8 @@ _kiwi.global = {
         }\r
 \r
         jobs.registerJob('load_text_theme');\r
-        text_theme = opts.text_theme;\r
-        if (!text_theme) {\r
-            $.getJSON(opts.base_path + '/assets/text_themes/default.json', textThemeLoaded);\r
-        } else {\r
-            $.getJSON(opts.base_path + '/assets/text_themes/' + text_theme + '.json', textThemeLoaded);\r
-        }\r
+        text_theme = opts.server_settings.client.settings.text_theme || 'default';\r
+        $.getJSON(opts.base_path + '/assets/text_themes/' + text_theme + '.json', textThemeLoaded);\r
     },\r
 \r
     start: function() {\r
index 4bfcc8e7e61057aec669510c8f440d6a7c3e62b3..66eb8354b70296eb7c5b2d5f8cde69b3d2321f17 100644 (file)
             opts.translations = data.translations;\r
             opts.locale = data.locale;\r
             opts.themes = data.themes;\r
-            opts.text_theme = data.server_settings.client.settings.text_theme;\r
 \r
             if (typeof data.kiwi_server !== 'undefined')\r
                 opts.kiwi_server = data.kiwi_server;\r