service-objecter 1.0.2 → 1.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/service_objecter.rb +5 -1
- data/lib/service_objecter/chainit_integration.rb +3 -7
- data/lib/service_objecter/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6645a84f848858d07ba1b4cdb9f476c8214f76e3
|
4
|
+
data.tar.gz: b534fc49c8f0a5f86f58b7d755b3f9bd38210528
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2f2c3da391be0767c8a1d358618cc64b94c758802981e7eb621f18f1a28d8f53dc732100943dc0e56feeba87df4e3564b886fbc6d91952284ac524ee88a72a1c
|
7
|
+
data.tar.gz: 307b75a8a11c5a2df28fe3574ca05105a98cbd48581a719e07cfb4a86ac8cd6cfa81bac79fc220fc95b28468eb64a86bd5b12aca5edffa1da94818e247a8f991
|
data/lib/service_objecter.rb
CHANGED
@@ -4,7 +4,7 @@ require 'service_objecter/chainit_integration'
|
|
4
4
|
module ServiceObjecter
|
5
5
|
def self.included(klass)
|
6
6
|
klass.extend(ClassMethods)
|
7
|
-
klass.include(ChainitIntegration) if defined?(ChainIt)
|
7
|
+
klass.include(ServiceObjecter::ChainitIntegration) if defined?(ChainIt)
|
8
8
|
end
|
9
9
|
|
10
10
|
module ClassMethods
|
@@ -41,6 +41,10 @@ module ServiceObjecter
|
|
41
41
|
@result ||= Result.new(true)
|
42
42
|
end
|
43
43
|
|
44
|
+
# def result=(*args)
|
45
|
+
# result.push(*args)
|
46
|
+
# end
|
47
|
+
|
44
48
|
# Transactions helper
|
45
49
|
# Simple usage
|
46
50
|
#
|
@@ -1,17 +1,12 @@
|
|
1
1
|
require 'forwardable'
|
2
|
+
|
2
3
|
module ServiceObjecter
|
3
4
|
module ChainitIntegration
|
4
5
|
extend(Forwardable)
|
5
6
|
|
6
|
-
|
7
|
-
__set_chain__
|
8
|
-
end
|
9
|
-
|
10
|
-
def_delegators :@__chain__, :chain, :skip_next, :on_error, :result
|
7
|
+
def_delegators :__get_chain__, :chain, :skip_next, :on_error, :result
|
11
8
|
alias run chain
|
12
9
|
|
13
|
-
private
|
14
|
-
|
15
10
|
def __set_chain__
|
16
11
|
@__chain__ = ChainIt.new
|
17
12
|
@__chain__.chain { ServiceObjecter::Result.new(true) }
|
@@ -19,6 +14,7 @@ module ServiceObjecter
|
|
19
14
|
end
|
20
15
|
|
21
16
|
def __get_chain__
|
17
|
+
__set_chain__ unless @__chain__
|
22
18
|
@__chain__
|
23
19
|
end
|
24
20
|
end
|