class Rodauth::Configuration

  1. lib/rodauth.rb
Superclass: Object

Methods

Public Class

  1. new

Public Instance

  1. apply
  2. auth
  3. enable

Attributes

auth [R]

Public Class methods

new(auth, &block)
[show source]
    # File lib/rodauth.rb
355 def initialize(auth, &block)
356   @auth = auth
357   # :nocov:
358   # Only for backwards compatibility
359   # RODAUTH3: Remove
360   apply(&block) if block
361   # :nocov:
362 end

Public Instance methods

apply(&block)
[show source]
    # File lib/rodauth.rb
364 def apply(&block)
365   load_feature(:base)
366   instance_exec(&block)
367 end
enable(*features)
[show source]
    # File lib/rodauth.rb
369 def enable(*features)
370   features.each do |feature|
371     next if @auth.features.include?(feature)
372     load_feature(feature)
373     @auth.features << feature
374   end
375 end