lib/redis/base_object.rb in redis-objects-1.4.3 vs lib/redis/base_object.rb in redis-objects-1.5.0

- old
+ new

@@ -1,7 +1,13 @@ +require 'redis/helpers/core_commands' + class Redis # Defines base functionality for all redis-objects. class BaseObject + include Redis::Helpers::CoreCommands + + attr_reader :key, :options + def initialize(key, *args) @key = key.is_a?(Array) ? key.flatten.join(':') : key @options = args.last.is_a?(Hash) ? args.pop : {} @myredis = Objects::ConnectionPoolProxy.proxy_if_needed(args.first) end