em-redislite 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/em-redislite.gemspec +1 -1
  2. data/lib/em/redis.rb +6 -2
  3. metadata +3 -3
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{em-redislite}
5
- s.version = '0.1.1'
5
+ s.version = '0.1.2'
6
6
  s.summary = 'A lightweight EM based Redis adapter'
7
7
  s.description = 'A very simple EventMachine based adapter that talks Redis protocol'
8
8
  s.authors = [ 'Bharanee Rathna' ]
@@ -10,7 +10,7 @@ module EM
10
10
  begin
11
11
  EM.connect options[:host], options[:port], Client, { host: options[:host], port: options[:port] }
12
12
  rescue ConnectionError => e
13
- client = Client.new ''
13
+ client = Client.new(nil)
14
14
  client.fail(Error.new(e.message))
15
15
  client
16
16
  end
@@ -19,7 +19,7 @@ module EM
19
19
  class Client < Connection
20
20
  include Deferrable
21
21
 
22
- def initialize options
22
+ def initialize options = {}
23
23
  @options = options
24
24
  end
25
25
 
@@ -31,6 +31,10 @@ module EM
31
31
  @lines = []
32
32
  end
33
33
 
34
+ def error?
35
+ signature ? super : true
36
+ end
37
+
34
38
  def command name, *args
35
39
  defer = DefaultDeferrable.new
36
40
  @pool << defer
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 1
8
- - 1
9
- version: 0.1.1
8
+ - 2
9
+ version: 0.1.2
10
10
  platform: ruby
11
11
  authors:
12
12
  - Bharanee Rathna
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-12-19 00:00:00 +11:00
17
+ date: 2011-06-21 00:00:00 +10:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency