business_flow 0.8.1 → 0.8.2

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
  SHA1:
3
- metadata.gz: 101cef083063da1cf0d92126d5dd7cc50bcb8091
4
- data.tar.gz: a7af18ecbcb1c2a2f9682357cef2c1651c18531b
3
+ metadata.gz: d21b7217a94afe45033d87426bf8628ca4575b9a
4
+ data.tar.gz: 80243c17f8ce51b704eb16b7da5dc0d909a1072c
5
5
  SHA512:
6
- metadata.gz: 4e1d0e0b14a29efe2497e0bedbb9ff39ab17628512f29980de7bb40fb9b4233df8db44c5d7719bda41b772ad0ac6008abdcd3c98b9aa2a62d107a09156186d9c
7
- data.tar.gz: 4d6fe2ec5df19806a666f2f452d50d8dbd91cebb58b0a32ad0676aac02e10e2c0c31a0e2a5a6da7bc5a1b565a97fa7101168b3c2abcc7464e88f8502d3710051
6
+ metadata.gz: 91b1128808b743615388bc72b636b6dc838f0d0275a6ceacd1a1c7fa33916aae39124eae90dc6fbacc5659b74d236818803bc12a75447c54a9447ae3e374d117
7
+ data.tar.gz: 82cbb8c46c60750c4d5a121c922f49d6a398e8eac537980dcc647bd0816e99cb98b045409687593c2806435b339cd54962e56022e685a8b6d8f0b2fc6f982d94
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- business_flow (0.8.1)
4
+ business_flow (0.8.2)
5
5
  activemodel (>= 3.0)
6
6
  activesupport (>= 3.0)
7
7
 
@@ -44,22 +44,24 @@ module BusinessFlow
44
44
  end
45
45
 
46
46
  def call(parameter_object)
47
- allocate.tap do |flow|
48
- catch(:halt_step) do
49
- flow.send(:_business_flow_dsl_initialize,
50
- ParameterObject.new(parameter_object), needs)
51
- execute(flow)
52
- end
53
- end
47
+ output = flow = build(parameter_object)
48
+ catch(:halt_step) { output = execute(flow) }
49
+ output
54
50
  end
55
51
 
56
52
  # :reek:UtilityFunction
57
53
  def execute(flow)
58
54
  flow.call
55
+ flow
59
56
  end
60
57
 
61
58
  def build(parameter_object)
62
- call(parameter_object)
59
+ allocate.tap do |flow|
60
+ catch(:halt_step) do
61
+ flow.send(:_business_flow_dsl_initialize,
62
+ ParameterObject.new(parameter_object), needs)
63
+ end
64
+ end
63
65
  end
64
66
 
65
67
  def call!(*args)
@@ -1,3 +1,3 @@
1
1
  module BusinessFlow
2
- VERSION = '0.8.1'.freeze
2
+ VERSION = '0.8.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: business_flow
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.1
4
+ version: 0.8.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alex Scarborough