Module: RedisHash::Core

Extended by:
ActiveSupport::Concern
Included in:
Base
Defined in:
lib/redis_hash/concerns/core.rb

Instance Method Summary collapse

Instance Method Details

#initialize(default = nil, redis: nil, redis_key: nil, redis_ttl: nil, &block) ⇒ Object



8
9
10
11
12
13
# File 'lib/redis_hash/concerns/core.rb', line 8

def initialize(default = nil, redis: nil, redis_key: nil, redis_ttl: nil, &block)
  run_callbacks(:initialize) do
    initialize_default(default, &block)
    initialize_redis(redis, redis_key, redis_ttl)
  end
end