app/controllers/sandbox_assets/base_controller.rb in rails-sandbox-assets-0.1.3 vs app/controllers/sandbox_assets/base_controller.rb in rails-sandbox-assets-0.2.0

- old
+ new

@@ -1,13 +1,14 @@ require_dependency "sandbox_assets/test_asset" module SandboxAssets class BaseController < ActionController::Base - before_filter :find_tests - before_filter :find_stylesheets - before_filter :extract_template_from_params - before_filter :render_template + before_action :skip_sprockets_precompiled_check + before_action :find_tests + before_action :find_stylesheets + before_action :extract_template_from_params + before_action :render_template # additional before_filters can use this def template=(template) @template = template end @@ -15,9 +16,13 @@ def iframe_template=(template) @iframe_template = template end protected + + def skip_sprockets_precompiled_check + Thread.current[:skip_precompiled_check] = true + end def find_tests @tests = TestAsset.find_tests(params) end