module Saasable::Railties::Helpers::ClassMethods
Public Instance Methods
saas_not_found_redirect_to(path_or_url)
click to toggle source
# File lib/saasable/railties/helpers.rb, line 25 def saas_not_found_redirect_to(path_or_url) class_eval <<-METHOD, __FILE__, __LINE__ + 1 private def _redirect_if_saas_not_found unless current_saas respond_to do |format| format.html { redirect_to "#{path_or_url}" } format.any { head :not_found } end end end METHOD end
skip_saasable(options)
click to toggle source
# File lib/saasable/railties/helpers.rb, line 39 def skip_saasable(options) skip_before_action :_redirect_if_saas_not_found, options.merge(raise: false) before_action :_skip_saasable, options end