shift site settings in front of routes

This commit is contained in:
Sam 2013-10-15 10:17:32 +11:00
parent e26cbe79ad
commit b567bd3d37
2 changed files with 1 additions and 1 deletions

View file

@ -227,7 +227,6 @@ Discourse = Ember.Application.createWithMixins(Discourse.Ajax, {
**/
start: function() {
Discourse.bindDOMEvents();
Discourse.SiteSettings = PreloadStore.get('siteSettings');
Discourse.MessageBus.alwaysLongPoll = Discourse.Environment === "development";
Discourse.MessageBus.start();
Discourse.KeyValueStore.init("discourse_", Discourse.MessageBus);

View file

@ -21,6 +21,7 @@
Discourse.BaseUrl = '<%= RailsMultisite::ConnectionManagement.current_hostname %>';
Discourse.BaseUri = '<%= Discourse::base_uri "/" %>';
Discourse.Environment = '<%= Rails.env %>';
Discourse.SiteSettings.login_required && !Discourse.User.current();
Discourse.Router.map(function() {
Discourse.routeBuilder.call(this);
});