interactor-initializer 1.1.1 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9dbb1b3df8198f7a2cf0dd09be4313c875d6ff41cd5dc4f2924becc9ca891002
4
- data.tar.gz: 428648c94139a36bdc625ac7a442801fe200fff722ad6614c16c12372308a6ff
3
+ metadata.gz: e4d09a6e72d6bf2916d4da84bb2c0b0db3b5bcafce4e0c212310ef08ca196605
4
+ data.tar.gz: c965f1464ede1eaf1daff6a8b8a60703a196074f6987abc3adbc67e4aa6a744a
5
5
  SHA512:
6
- metadata.gz: 8aac43874ea1b6e9b1f5a2e90c0f8bfa5e65a3efba9a3568cdc3c864d20ac423f1dfdff2f4afc24d245b26083bcf1ae8bafb6de83defaaa274e62f271796d9d8
7
- data.tar.gz: e5613dde388af09f4a7fb0f4985cbd8b6441ada98cb9163599f8a69c72a11788e9be186b9dbd4f695e13886b6fcf07dcf1708d876f9da0011a51ce4c0716234d
6
+ metadata.gz: 3d5cddeabd1a19537e500b700fb5337104741fff903cb1653ac9b9efc51f36ca2b7d4e170a490a2ef0c68f39925a33c60b53e9148e5e6e942634c9390cd6b9c4
7
+ data.tar.gz: 9a6889f3e12e258b2fa94efa5fabaf417327fa0873762e9a7cb622ff1509f9b764543fd7ba665fce46acf4071e7a2c86b2350b1ad91b6b269d136b541b4b531a
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- interactor-initializer (1.1.1)
4
+ interactor-initializer (1.2.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -24,18 +24,20 @@ class Interactor::Initializer::Helper
24
24
  end
25
25
  end
26
26
 
27
- def self.methods_with_params
27
+ def self.methods_with_params(attributes = [])
28
+ signature = attributes.join(', ')
29
+
28
30
  <<-RUBY
29
- def self.for(*args)
30
- new(*args).run
31
+ def self.for(#{signature})
32
+ new(#{signature}).run
31
33
  end
32
34
 
33
- def self.run(*args)
34
- new(*args).run
35
+ def self.run(#{signature})
36
+ new(#{signature}).run
35
37
  end
36
38
 
37
- def self.with(*args)
38
- new(*args).run
39
+ def self.with(#{signature})
40
+ new(#{signature}).run
39
41
  end
40
42
  RUBY
41
43
  end
@@ -1,5 +1,5 @@
1
1
  module Interactor
2
2
  module Initializer
3
- VERSION = '1.1.1'.freeze
3
+ VERSION = '1.2.0'.freeze
4
4
  end
5
5
  end
@@ -17,7 +17,7 @@ module Interactor
17
17
 
18
18
  def initialize_with(*attributes)
19
19
  signature = attributes.join(', ')
20
- class_methods = Interactor::Initializer::Helper.methods_with_params
20
+ class_methods = Interactor::Initializer::Helper.methods_with_params(attributes)
21
21
 
22
22
  Interactor::Initializer::Helper.modify_class(self, signature, attributes, class_methods)
23
23
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: interactor-initializer
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Šarūnas Kūjalis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-06-10 00:00:00.000000000 Z
11
+ date: 2023-06-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler