From 61384c802642da0c3d3e1d87371624929dca014a Mon Sep 17 00:00:00 2001 From: Vinoth Kannan Date: Wed, 10 Jan 2018 01:24:03 +0530 Subject: [PATCH] Skip CDN for admin locales since it is login required --- app/controllers/extra_locales_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/extra_locales_controller.rb b/app/controllers/extra_locales_controller.rb index 6ee44ffa2fa..0f28804c778 100644 --- a/app/controllers/extra_locales_controller.rb +++ b/app/controllers/extra_locales_controller.rb @@ -24,7 +24,7 @@ class ExtraLocalesController < ApplicationController def self.url(bundle) if Rails.env == "production" - "#{SiteSetting.login_required ? "" : GlobalSetting.cdn_url}#{Discourse.base_uri}/extra-locales/#{bundle}?v=#{bundle_js_hash(bundle)}" + "#{SiteSetting.login_required || bundle =~ /^(admin|wizard)$/ ? "" : GlobalSetting.cdn_url}#{Discourse.base_uri}/extra-locales/#{bundle}?v=#{bundle_js_hash(bundle)}" else "#{Discourse.base_uri}/extra-locales/#{bundle}" end