Sha256: 1c638005a3da8433c95392ef6cf59d0aee52052e7d52e7a83864c3b1f28b47db

Contents?: true

Size: 385 Bytes

Versions: 14

Compression:

Stored size: 385 Bytes

Contents

module ActsAsTenant
  @@configuration = nil

  def self.configure
    @@configuration = Configuration.new

    if block_given?
      yield configuration
    end

    configuration
  end

  def self.configuration
    @@configuration || configure
  end

  class Configuration
    attr_writer :require_tenant
  
    def require_tenant
      @require_tenant ||= false
    end
  
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
acts_as_tenant-0.4.4 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.4.3 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.4.2 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.4.1 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.4.0 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.9 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.8 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.7 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.6 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.5 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.4 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.3 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.2 lib/acts_as_tenant/configuration.rb
acts_as_tenant-0.3.1 lib/acts_as_tenant/configuration.rb