relix 1.4.0 → 1.4.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- NDQwM2VkOWJiYjk5NGQzYmNiMjA4ZThjNzQ3ZDRmNmQzZDJmZjRlZg==
4
+ Yzc4YzAwNWQ2OTc0NmU4NjYxOTRjMzNiMTliNGYwZTQyM2E1NDYzOA==
5
5
  data.tar.gz: !binary |-
6
- N2Q3YTYyZWEyNjk2YTFjOGNiODQ0MDhmMGFmNTY1NTI5NDUxODE2ZQ==
6
+ OWU3YjljMmY1NjZlNmZlMjBhYTk5MjFmOWY2ZmYxZjQxZjg1ZDljOQ==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- YzI2MTNmZmVmYTVlNTllNmQ2NDhkOTUxYjkwM2IxNGQ0NGI1NjQzMGNiYmE3
10
- NWUxNjIzYjk1YWI1OGNkODdlYTNiMmZlNTcwZjdmOWI0MzlmYzYwMjAxMzQw
11
- YWM5NzAwZGU2ODE5ZmMzOGExMzY2NmE5OWE2NGYzZDdkMzczYzY=
9
+ YzYzOTk2YjQyZWI3MjU1MjEyZmEyNmIwYjQxYmFjZWFlNWRjYWFmZmRlYzlh
10
+ NjM2M2Y5ZjBhYjgxNGE5NzdiZjdkNmQ3ZjE1N2Y4NDFjZTI3Nzk1ZWY3YjUx
11
+ YjY3YTRjMDA0YmI0MTc0NzFiNWYxZTAyODViZjFlZmMzZDhkZjA=
12
12
  data.tar.gz: !binary |-
13
- ZTgxNzA5Y2I0YjZkMTVlYjM4NzBkYzUwYTAyNTExOTIwOTYwOGZlZWVmNjk3
14
- Mjg3ZmVlNWQ2YWMyNGNhZWMzNzlhMTY1YjYwNWM0ZTNjMGU5YzY0ZTRmYTYz
15
- MzdkY2E2NzczYTRlYTkyNjA0ZTY3M2ZkODZhNDNhYjM0OTBiZTk=
13
+ OTQ1MzljMWFhZjBjMjQ3ZWI5MGE4NDRmOWVkODQwNmRiMDdkYThlNjM2YTk5
14
+ ZmE0Zjc0M2ZkYjI3MzE5MTI1NjNiYjk0NTA2YTc4NGJkZDg3MjAyNTAyNmU5
15
+ NmMzZjEyMjJlN2FiN2M5MjdmZGExMmZhMTQxMDQzMDlkNjBkZmM=
data/HISTORY.md CHANGED
@@ -1,3 +1,7 @@
1
+ ### 1.4.1
2
+
3
+ * Fix double #deindex_by_primary_key when there's a multi index. (ntalbott)
4
+
1
5
  ### 1.4.0
2
6
 
3
7
  * Add #deindex_by_primary_key. (ntalbott)
@@ -112,7 +112,7 @@ module Relix
112
112
  current_values[name]
113
113
  end
114
114
 
115
- ((watch = index.watch(old_value)) && @redis.watch(*watch))
115
+ ((watch = index.watch(old_value)) && !watch.empty? && @redis.watch(*watch))
116
116
  proc { index.deindex(@redis, pk, old_value) }
117
117
  end.tap { |ops| ops << proc { @redis.del current_values_name } }
118
118
  end
@@ -127,7 +127,7 @@ module Relix
127
127
  indexes.map do |name, index|
128
128
  old_value = current_values[name]
129
129
 
130
- ((watch = index.watch(old_value)) && @redis.watch(*watch))
130
+ ((watch = index.watch(old_value)) && !watch.empty? && @redis.watch(*watch))
131
131
  proc { index.deindex(@redis, pk, old_value) }
132
132
  end.tap { |ops| ops << proc { @redis.del current_values_name } }
133
133
  end
@@ -173,7 +173,7 @@ module Relix
173
173
  end
174
174
  end
175
175
  rescue Redis::CommandError => e
176
- raise RedisIndexingError.new(e.message)
176
+ raise RedisIndexingError, e.message, e.backtrace
177
177
  end
178
178
 
179
179
  def primary_key_for(object)
data/lib/relix/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Relix
2
- VERSION = "1.4.0"
2
+ VERSION = "1.4.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: relix
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathaniel Talbott