mobility 1.2.6 → 1.2.7
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 +4 -4
- checksums.yaml.gz.sig +0 -0
- data/CHANGELOG.md +5 -0
- data/Gemfile.lock +4 -0
- data/README.md +1 -1
- data/lib/mobility/plugins/active_record/query.rb +4 -1
- data/lib/mobility/plugins/sequel/query.rb +4 -1
- data/lib/mobility/version.rb +1 -1
- data.tar.gz.sig +0 -0
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f9ff30d2d033cff7555cc4a4ed4d463d7670df67e4e23302534f35fc6bf34649
|
|
4
|
+
data.tar.gz: d3097e35c0d8e6fc65c88fc038fcb056add50c4a87384ece6e71321c33a71aac
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 10b8f7d41910f51e21fbf6ad5603e284070c202d224518b788067df6ea4fc77f180b2273498307a8f5d77f88963eee06917bea68f51a41d98308c60bc2091cf5
|
|
7
|
+
data.tar.gz: 20cdcc3adc28dae960ea83a58b1aa2ba92515e824a6ebe35a4bb3d896c9b0eae3aae0b8198c32304dfb9d2eec8a794b427a50f3f4f0c75e0b2e8d307ad40fb69
|
checksums.yaml.gz.sig
CHANGED
|
Binary file
|
data/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
## 1.2
|
|
4
4
|
|
|
5
|
+
### 1.2.7
|
|
6
|
+
- Do not query same attribute more than once, fixes
|
|
7
|
+
[#564](https://github.com/shioyama/mobility/pull/578)
|
|
8
|
+
([#577](https://github.com/shioyama/mobility/pull/577))
|
|
9
|
+
|
|
5
10
|
### 1.2.6
|
|
6
11
|
- Require mfa on rubygems
|
|
7
12
|
([#545](https://github.com/shioyama/mobility/pull/545))
|
data/Gemfile.lock
CHANGED
|
@@ -41,6 +41,7 @@ GEM
|
|
|
41
41
|
notiffany (0.1.3)
|
|
42
42
|
nenv (~> 0.1)
|
|
43
43
|
shellany (~> 0.0)
|
|
44
|
+
pg (1.3.5)
|
|
44
45
|
pry (0.13.1)
|
|
45
46
|
coderay (~> 1.1)
|
|
46
47
|
method_source (~> 1.0)
|
|
@@ -67,6 +68,7 @@ GEM
|
|
|
67
68
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
68
69
|
rspec-support (~> 3.10.0)
|
|
69
70
|
rspec-support (3.10.2)
|
|
71
|
+
sequel (5.57.0)
|
|
70
72
|
shellany (0.0.1)
|
|
71
73
|
thor (1.1.0)
|
|
72
74
|
yard (0.9.26)
|
|
@@ -79,9 +81,11 @@ DEPENDENCIES
|
|
|
79
81
|
database_cleaner (~> 1.5, >= 1.5.3)
|
|
80
82
|
guard-rspec
|
|
81
83
|
mobility!
|
|
84
|
+
pg
|
|
82
85
|
pry-byebug
|
|
83
86
|
rake (~> 12, >= 12.2.1)
|
|
84
87
|
rspec (~> 3.0)
|
|
88
|
+
sequel (~> 5.0)
|
|
85
89
|
yard (~> 0.9.0)
|
|
86
90
|
|
|
87
91
|
BUNDLED WITH
|
data/README.md
CHANGED
|
@@ -223,10 +223,13 @@ enabled for any one attribute on the model.
|
|
|
223
223
|
|
|
224
224
|
keys, predicates = opts.keys.map(&:to_s), []
|
|
225
225
|
|
|
226
|
+
used_keys = []
|
|
227
|
+
|
|
226
228
|
query_map = mods.inject(IDENTITY) do |qm, mod|
|
|
227
|
-
i18n_keys = mod.names & keys
|
|
229
|
+
i18n_keys = mod.names & keys - used_keys
|
|
228
230
|
next qm if i18n_keys.empty?
|
|
229
231
|
|
|
232
|
+
used_keys += i18n_keys
|
|
230
233
|
mod_predicates = i18n_keys.map do |key|
|
|
231
234
|
build_predicate(scope.backend_node(key.to_sym, locale), opts.delete(key))
|
|
232
235
|
end
|
|
@@ -135,10 +135,13 @@ ActiveRecord query plugin.
|
|
|
135
135
|
keys, predicates = cond.keys, []
|
|
136
136
|
model = dataset.model
|
|
137
137
|
|
|
138
|
+
used_keys = []
|
|
139
|
+
|
|
138
140
|
query_map = attribute_modules(model).inject(IDENTITY) do |qm, mod|
|
|
139
|
-
i18n_keys = mod.names.map(&:to_sym) & keys
|
|
141
|
+
i18n_keys = mod.names.map(&:to_sym) & keys - used_keys
|
|
140
142
|
next qm if i18n_keys.empty?
|
|
141
143
|
|
|
144
|
+
used_keys += i18n_keys
|
|
142
145
|
mod_predicates = i18n_keys.map do |key|
|
|
143
146
|
build_predicate(dataset.backend_op(key, locale), cond.delete(key))
|
|
144
147
|
end
|
data/lib/mobility/version.rb
CHANGED
data.tar.gz.sig
CHANGED
|
Binary file
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: mobility
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.2.
|
|
4
|
+
version: 1.2.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Chris Salzberg
|
|
@@ -34,7 +34,7 @@ cert_chain:
|
|
|
34
34
|
QHgocnSksU5GOM+G2UhjVycbTamd+bCxjWAZTEDZNafFt5CmnfK1D1UTIblR/ci9
|
|
35
35
|
fUDdW+GhxhobB8N1mtDRlhELoxLLjx7mSvJ3Wg==
|
|
36
36
|
-----END CERTIFICATE-----
|
|
37
|
-
date: 2022-
|
|
37
|
+
date: 2022-06-18 00:00:00.000000000 Z
|
|
38
38
|
dependencies:
|
|
39
39
|
- !ruby/object:Gem::Dependency
|
|
40
40
|
name: request_store
|
metadata.gz.sig
CHANGED
|
Binary file
|