namespace_extensions.rb 276 B

123456789101112
  1. # frozen_string_literal: true
  2. class Redis
  3. module NamespaceExtensions
  4. def exists?(*args, &block)
  5. call_with_namespace('exists?', *args, &block)
  6. end
  7. end
  8. end
  9. Redis::Namespace::COMMANDS['exists?'] = [:first]
  10. Redis::Namespace.prepend(Redis::NamespaceExtensions)