From e4308cdc53ec6882fa970a88ec28db0a2d4bf8e3 Mon Sep 17 00:00:00 2001 From: Yan Date: Fri, 10 Nov 2017 18:10:19 +0630 Subject: [PATCH] license test remove --- app/controllers/application_controller.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 14838c20..f6d3c957 100755 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -23,8 +23,8 @@ class ApplicationController < ActionController::Base end def lookup_domain - # if request.subdomain.present? && request.subdomain != "www" - @license = current_license(ENV["SX_PROVISION_URL"], "chromis") # request.subdomain.downcase + if request.subdomain.present? && request.subdomain != "www" + @license = current_license(ENV["SX_PROVISION_URL"], request.subdomain.downcase) # request.subdomain.downcase if (!@license.nil?) # logger.info "Location - " + @license.name ActiveRecord::Base.establish_connection(website_connection(@license)) @@ -35,7 +35,7 @@ class ApplicationController < ActionController::Base # redirect_to root_url(:host => request.domain) + "store_error" render :json => [{ status: false, message: 'Invalid Access!'}] end - # end + end end def current_license(url, subdomain)