Sha256: 48184306cead94fcf64489ada789f3a92f624cb272ee5e01a4c92e6159112848

Contents?: true

Size: 574 Bytes

Versions: 1

Compression:

Stored size: 574 Bytes

Contents

# frozen_string_literal: true

# rubocop:disable Style/ClassAndModuleChildren

begin
  require 'fakeredis'
rescue LoadError
  require 'redis'
end

module ActiveOrm
  module Redis
    class Configuration

      attr_accessor :client

      def initialize
        @client = ::Redis.new
      end

    end

    def self.configuration
      @configuration ||= Configuration.new
    end

    def self.configuration=(config)
      @configuration = config
    end

    def self.configure
      yield(configuration)
    end

  end
end

# rubocop:enable Style/ClassAndModuleChildren

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
active_orm-5.1.0 lib/active_orm/redis/configuration.rb