couch_view 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -19,6 +19,10 @@ module CouchView
19
19
  @reduce ||= "_count"
20
20
  end
21
21
  end
22
+
23
+ def conditions_config
24
+ @conditions
25
+ end
22
26
 
23
27
  def conditions(*args, &block)
24
28
  if args.empty? && block.nil?
@@ -15,7 +15,9 @@ module CouchView
15
15
  base_view_name = view_config.base_view_name
16
16
 
17
17
  if view_configs[base_view_name]
18
- view_config.conditions *view_configs[base_view_name].conditions
18
+ view_configs[base_view_name].conditions.each do |condition_name, condition_module|
19
+ view_config.conditions_config.send condition_name, condition_module
20
+ end
19
21
  view_configs[base_view_name] = view_config
20
22
  else
21
23
  view_configs[base_view_name] = view_config
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: couch_view
3
3
  version: !ruby/object:Gem::Version
4
- hash: 27
4
+ hash: 25
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 0
10
- version: 0.1.0
9
+ - 1
10
+ version: 0.1.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Matt Parker