statinize 0.3.0 → 0.3.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
  SHA256:
3
- metadata.gz: 667a2ecdfba95106c743143e47a3373c1c5dab105f82b1f69b3384c84e2aeb4a
4
- data.tar.gz: f1005a83f8ae7a816f1b9bea2f8cdca1812e4bcd7a32bed2b928a8338fe68682
3
+ metadata.gz: 8076207399abda2e6f39e33f71e78a318819bbdb9cd7ae759d6a896f62cf49ce
4
+ data.tar.gz: 53378fe3b67039c26472294ac3061c2d9a2dbd7801a77d61602f6804e05c389e
5
5
  SHA512:
6
- metadata.gz: 0b888eaccd5ae0e23cc8a303abdaf8207fcc0f1bcd618bbe1985d71e3fc1b77c2b4e65e5a98bdcd04468e7977a37c69a8af732b1d1035c856f7fe0561b5359a7
7
- data.tar.gz: bd422a1a7ddb0b917c895ebc8078b071b07bc1b35cb2090c2750a451df119adc668ba9e727d1ad11b534f44a37a58772ddc7f6837e996970d6990d75b7d38f9a
6
+ metadata.gz: a6919c84d1fb55b306fc37663152b438c23b199dc952d68e4ee8618d9f2987be236583f7bf7035a9c1e1397edfcd70b58e09a99d71ef4e87d9d3a210cd893c8f
7
+ data.tar.gz: 6f6d9af898f648a285f377bed8f5be59ab9045f67296dfd7ed4bc0807a544f8bc62aef377c585d1f2ddd258d9b5012a6c1eff95c1a0c5fe36071bf1f951b321f
@@ -12,7 +12,7 @@ module Statinize
12
12
  klass.instance_variable_set("@statinizer", Statinizer.new(klass))
13
13
 
14
14
  statinized_ancestors.each do |ancestor|
15
- klass.statinizer.populate(ancestor.statinizer.attributes)
15
+ klass.statinizer.populate(ancestor.statinizer.attributes) if ancestor.statinizer
16
16
  end
17
17
  end
18
18
  end
@@ -20,8 +20,6 @@ module Statinize
20
20
  module PrependedMethods
21
21
  def initialize(options = {}, *args, **kwargs, &block)
22
22
  symbolized = kwargs.merge(options).transform_keys(&:to_sym)
23
- extra_attributes = symbolized.keys.map(&:to_sym) - statinizer.attributes.map(&:name).map(&:to_sym)
24
- raise UnknownAttributeError, "Attributes #{extra_attributes.join(", ")} are unknown" if extra_attributes.any?
25
23
 
26
24
  if private_methods(false).include? :initialize
27
25
  super(*args, **kwargs, &block)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: statinize
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Barseek
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-09-25 00:00:00.000000000 Z
11
+ date: 2022-09-26 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Statinization gem. Allows for creation of attributes for a class with
14
14
  a given type.