use_cases 2.0.2 → 2.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/use_cases/dsl.rb +4 -0
- data/lib/use_cases/step_adapters/abstract.rb +5 -6
- data/lib/use_cases/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0e64ac5284a76952a2d0da6e2d48ea40b93af03926b5f4d0a23a38698836dfe0
|
4
|
+
data.tar.gz: b9c894909398b9cc287da875175f125319243b0dd077158d27b59e498e184cbe
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a34740d4caa9274eeed8e76ebc20293c3dc1e962551b35b3c14b885e018135d51a7f27f832b9ca02b0639a6bf4e4e4febcf4567bd7ed6531077940e709f9e84f
|
7
|
+
data.tar.gz: 728d1da8f92f9d375b11172fc68f4b8aab7e4b9efa048a88959bd9996d327a27bda9432948fdd82d8dcae0fab05a64e4127efb343441b7d4f0e8e5b66d1ed31b
|
data/Gemfile.lock
CHANGED
data/lib/use_cases/dsl.rb
CHANGED
@@ -38,18 +38,17 @@ module UseCases
|
|
38
38
|
raise StepArgumentError,
|
39
39
|
"##{step.name} expects #{expected_args_count} arguments it only received #{step_args.count}, make sure your previous step Success() statement has a payload."
|
40
40
|
end
|
41
|
-
|
42
41
|
return args.first(callable_args_count) unless external? && selects_external_args?
|
43
42
|
|
44
43
|
hashed_args(args).values
|
45
44
|
end
|
46
45
|
|
47
|
-
def hashed_args(
|
46
|
+
def hashed_args((prev_result, params, current_user))
|
48
47
|
{
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
}.slice(pass_option)
|
48
|
+
previous_step_result: prev_result,
|
49
|
+
params: params,
|
50
|
+
current_user: current_user,
|
51
|
+
}.slice(*pass_option)
|
53
52
|
end
|
54
53
|
|
55
54
|
def callable_proc
|
data/lib/use_cases/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: use_cases
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ring Twice
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-09-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|