rom-repository 5.2.1 → 5.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/rom/repository.rb +15 -2
- data/lib/rom/repository/version.rb +1 -1
- metadata +9 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 550a6edbadf63192bfb25f13730d36333249b4d62a09ae50082293673ec2323d
|
4
|
+
data.tar.gz: ded42536cbd47227855fd97fa29c264579a25cd60f546e83e76d51f170422a8a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f190a22779c2f484ae5707f96b543b47b3682d8e55aee281d45761cc20f68aedb85b09ef19f278c09829f0ea1ef6911cc848e81d634b93b0d4ebf8447c4acaca
|
7
|
+
data.tar.gz: acde1423d52bc20df33ad05197de2727a20e2e8de12dd262de4a726c715a31975c1fbcfbe95d799b5030ed92e0f174e540197bf9fdb769bcc398aba422d579e3
|
data/lib/rom/repository.rb
CHANGED
@@ -132,9 +132,22 @@ module ROM
|
|
132
132
|
# user
|
133
133
|
# # nil
|
134
134
|
#
|
135
|
+
# @example with automatic savepoints
|
136
|
+
# user = transaction(auto_savepoint: true) do
|
137
|
+
# create(changeset(name: 'Jane'))
|
138
|
+
#
|
139
|
+
# transaction do |t|
|
140
|
+
# update(changeset(name: 'John'))
|
141
|
+
# t.rollback!
|
142
|
+
# end
|
143
|
+
# end
|
144
|
+
#
|
145
|
+
# user
|
146
|
+
# # => #<ROM::Struct::User id=1 name="Jane">
|
147
|
+
#
|
135
148
|
# @api public
|
136
|
-
def transaction(&block)
|
137
|
-
container.gateways[:default].transaction(&block)
|
149
|
+
def transaction(*args, &block)
|
150
|
+
container.gateways[:default].transaction(*args, &block)
|
138
151
|
end
|
139
152
|
|
140
153
|
# Return a string representation of a repository object
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rom-repository
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.2.
|
4
|
+
version: 5.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Piotr Solnica
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-03-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dry-initializer
|
@@ -51,6 +51,9 @@ dependencies:
|
|
51
51
|
- - "~>"
|
52
52
|
- !ruby/object:Gem::Version
|
53
53
|
version: '5.2'
|
54
|
+
- - ">="
|
55
|
+
- !ruby/object:Gem::Version
|
56
|
+
version: 5.2.2
|
54
57
|
type: :runtime
|
55
58
|
prerelease: false
|
56
59
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -58,6 +61,9 @@ dependencies:
|
|
58
61
|
- - "~>"
|
59
62
|
- !ruby/object:Gem::Version
|
60
63
|
version: '5.2'
|
64
|
+
- - ">="
|
65
|
+
- !ruby/object:Gem::Version
|
66
|
+
version: 5.2.2
|
61
67
|
- !ruby/object:Gem::Dependency
|
62
68
|
name: rake
|
63
69
|
requirement: !ruby/object:Gem::Requirement
|
@@ -125,7 +131,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
125
131
|
- !ruby/object:Gem::Version
|
126
132
|
version: '0'
|
127
133
|
requirements: []
|
128
|
-
rubygems_version: 3.1.
|
134
|
+
rubygems_version: 3.1.2
|
129
135
|
signing_key:
|
130
136
|
specification_version: 4
|
131
137
|
summary: Repository abstraction for rom-rb
|