Method: Incline::Extensions::ActionControllerBase::ClassMethods#allow_non_ssl

Defined in:
lib/incline/extensions/action_controller_base.rb

#allow_non_ssl(*args) ⇒ Object

Enables or disables HTTP (non-SSL) for actions.

Pass false to disable HTTP for all actions(default). Pass true to enable HTTP for all actions. Pass action names to enable HTTP for specific actions.

With no arguments, the current setting is returned.

allow_non_ssl false
allow_non_ssl true
allow_non_ssl :home, :about


44
45
46
47
48
49
50
# File 'lib/incline/extensions/action_controller_base.rb', line 44

def allow_non_ssl(*args)
  if args.blank?
    @allow_non_ssl ||= false
  else
    @allow_non_ssl = setting_value(args)
  end
end