polyblock 0.1.7 → 0.1.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 867bc80f97b3015cae52d8a52c2e6ce8d398251d
4
- data.tar.gz: 3b4a29196d4a63af11997298e37cfc0f7be56719
3
+ metadata.gz: bcf7f2596688a81fd5a08c97a237f43be4bb80c5
4
+ data.tar.gz: 96adb94234445ca164286b352b9598aeaaa99979
5
5
  SHA512:
6
- metadata.gz: 1f73cf99fe2a23ed589f38c3a7494be96438292e292a01f98facec2c4cb132769cae7458ba8ce34bf6bff7763ad74bf9c34111aa1743190f6fed15dbe81afea9
7
- data.tar.gz: f6da8516842789e6f74669e576f7d52eca0dbc145e424d9b2f07650f61ad813f54cbc36cc06aa046e694f8f75de0144741a2177acd87f5b94b7cab28d4d691e8
6
+ metadata.gz: 2f60fd4033a0db11301798229cd3966f52afd111c3199c300e2ea2836a7a948fa7ba853a8bcf116cfb66268e47d54d22fce51f5e47d858ed1d205acff4171467
7
+ data.tar.gz: 9db39a46d91fb8a87bf545822492916319d1e0f7f497c21e2052b3578630b855584bc14938d6d6e8eb6f1f9a9b42b07a95c294171ccbca574ece4ed567ef443d
@@ -7,8 +7,8 @@ module Polyblock
7
7
 
8
8
  module ClassMethods
9
9
  def has_polyblock(name, options={})
10
- defaults = {:class_name => "Polyblock::Block", :as => :contentable, :conditions => {:name => name}}
11
- has_one name, defaults.merge(options)
10
+ defaults = {:class_name => "Polyblock::Block", :as => :contentable}
11
+ has_one name, -> { where(:name => name) }, defaults.merge(options)
12
12
  accepts_nested_attributes_for name
13
13
  include Polyblock::HasPolyblock::LocalInstanceMethods
14
14
  end
@@ -1,3 +1,3 @@
1
1
  module Polyblock
2
- VERSION = "0.1.7"
2
+ VERSION = "0.1.8"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: polyblock
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - MacKinley Smith
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-12-21 00:00:00.000000000 Z
11
+ date: 2014-01-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails