setsy 0.1.1 → 0.1.2

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: 6d2a5a417db1b43122c70808edae2f3df2e7f7d1
4
- data.tar.gz: 399e2312ad02292ffd02c44b8a56dbd7826dc947
3
+ metadata.gz: 2f86afe01e5815478a66c597d623ec4e4e5a94cf
4
+ data.tar.gz: b827177acaa78e096b2ed40dc2eca1b5cc98a398
5
5
  SHA512:
6
- metadata.gz: 711c93ce77d4dc15587fcb8018a79012b57ab774ec778ca2dbc897bdfce797260b4a20c10d5e91a497b1cab1c299ecf425ea087465c84a542a4b2fe71840323c
7
- data.tar.gz: 3dfcac1418323e1d435fa6b298e3e6ff2f3209c9d145ae0cc9b7f932d68037f795966fe161211c6edad1eb69fdd873c4f2fbbfb4fe81828b2f737b5006e11808
6
+ metadata.gz: 43240b7e3d6d046d7208c09ed5e15929a8927302eac095bbfc9de9c6c02ae44b91b1a46e39e7f2b01e491b9e8b8dcbeaa0b98c069e55b9bc9fd86d74b1eebf7c
7
+ data.tar.gz: c753a8c1290e7e835a084e6def33bce9b88dc63e19f71d1af1430c429a2d6cfc108088884c990cd2ab0f8a3167bf16b73d53cf3cbc0852a690add92bbd57e9ba
@@ -3,10 +3,11 @@ module Setsy
3
3
  def self.included(base)
4
4
  base.extend ClassMethods
5
5
  end
6
-
7
6
  module ClassMethods
8
7
  def setsy(attribute_name, options = {})
9
8
  readers = {}
9
+ options[:column] ||= "#{attribute_name}_data".to_sym
10
+ options[:defaults] ||= self.const_defined?(:SETSY_DEFAULTS) ? self.const_get(:SETSY_DEFAULTS) : {}
10
11
  readers = yield(Setsy::Configuration) if block_given?
11
12
  class_eval do
12
13
  define_method(:setsy_configuration) do
@@ -1,3 +1,3 @@
1
1
  module Setsy
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: setsy
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Josh Brody
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-07-08 00:00:00.000000000 Z
11
+ date: 2018-07-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails