parascope 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/CHANGELOG +4 -0
- data/lib/parascope/query.rb +1 -1
- data/lib/parascope/query/api_methods.rb +8 -0
- data/lib/parascope/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9ae9437f9c91dc9a6f126c16b6f3c4a2c745634d
|
4
|
+
data.tar.gz: 859be0e8b38ecc4e6af3d9fb0d379e464f54ab7e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 49ad2eccded8195f771ad943704a9df0fbf56c62fc52ca00474311140b366f42a98e093c55f1a5ae4c89151640747286f93464f6790ccef1a52918afd7ee15ae
|
7
|
+
data.tar.gz: 73c4988ec96e88e9973f6031d3ecd9bd48474777f3271d7f83ffd29c0ba7107dd278cc09c9dfe3ebd821684780d594b1647bd92ab2cc22670ce09c33a50e6a3d
|
data/CHANGELOG
CHANGED
data/lib/parascope/query.rb
CHANGED
@@ -73,7 +73,7 @@ module Parascope
|
|
73
73
|
|
74
74
|
def resolved_scope!
|
75
75
|
guard_all
|
76
|
-
klass.
|
76
|
+
klass.sorted_query_blocks.reduce(scope) do |scope, block|
|
77
77
|
clone_with_scope(scope, block).apply_block!.scope
|
78
78
|
end
|
79
79
|
end
|
@@ -48,5 +48,13 @@ module Parascope
|
|
48
48
|
def guard_blocks
|
49
49
|
@guard_blocks ||= []
|
50
50
|
end
|
51
|
+
|
52
|
+
def sorted_query_blocks
|
53
|
+
query_blocks.sort do |a, b|
|
54
|
+
a.index == b.index \
|
55
|
+
? query_blocks.index(a) <=> query_blocks.index(b)
|
56
|
+
: a.index <=> b.index
|
57
|
+
end
|
58
|
+
end
|
51
59
|
end
|
52
60
|
end
|
data/lib/parascope/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: parascope
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Artem Kuzko
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-07-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: hashie
|