graphoid 0.0.1 → 0.0.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 570048f8ac7a5863e2649feabf58df51352c8736a8d94f8009ce666d26f21e67
4
- data.tar.gz: 3168975860650e784303f5cc57851b4ed7106e360dc55af30077f02c4c0a6f1a
3
+ metadata.gz: 5f060ce3dc46c8bf367aeec184daa225ebbe3d33471a37492f668b61a917e23d
4
+ data.tar.gz: a62c8e9a0abd9c10b0a8842bdb5ca75a8cf8050fba088db794f723376a966f27
5
5
  SHA512:
6
- metadata.gz: 3e8eae2534153a462a4a705ddf43176146b5042d64d812f5dd62d246bba0dfece3f306539f6e19eba33329e81e7aabb95d07ceecd21e0ecca419e347c2314963
7
- data.tar.gz: cc0450a2be3f570fca4178aaf969ebf93aa3c981faf2ce43bdf6e079193c1c62bf8e3e38d77eda5d6ae64e271f3c7bacd9bc735256497e15879fcf1a5cee7afb
6
+ metadata.gz: d183869e672db7ccb37a72e9c3fea49db92add12130e4a59c1e1cfa3f69d04db60fcad8141e99f0b8167ab2b3eb068eefde7c768be71e096001fd5117af7f470
7
+ data.tar.gz: f5f2fa9be4b6052c10b036f9b5bc2f9c9dd59025b14aa2ecdf09c9885072686b3ebe09442dd47daf842c888a7323c4c52ce2b2717acad15f136e0544af9bb4be
@@ -56,13 +56,13 @@ module Graphoid
56
56
 
57
57
  def class_of(relation)
58
58
  {
59
- Mongoid::Relations::Referenced::ManyToMany => ManyToMany,
60
- Mongoid::Relations::Referenced::Many => HasMany,
61
- Mongoid::Relations::Referenced::One => HasOne,
62
- Mongoid::Relations::Referenced::In => BelongsTo,
63
- Mongoid::Relations::Embedded::Many => EmbedsMany,
64
- Mongoid::Relations::Embedded::One => EmbedsOne,
65
- Mongoid::Relations::Embedded::In => Relation
59
+ Mongoid::Association::Referenced::HasAndBelongsToMany => ManyToMany,
60
+ Mongoid::Association::Referenced::HasMany => HasMany,
61
+ Mongoid::Association::Referenced::HasOne => HasOne,
62
+ Mongoid::Association::Referenced::BelongsTo => BelongsTo,
63
+ Mongoid::Association::Embedded::EmbedsMany => EmbedsMany,
64
+ Mongoid::Association::Embedded::EmbedsOne => EmbedsOne,
65
+ Mongoid::Association::Embedded::EmbeddedIn => Relation
66
66
  }[relation.relation] || Relation
67
67
  end
68
68
 
@@ -88,10 +88,10 @@ module Graphoid
88
88
 
89
89
  def eager_load(selection, model)
90
90
  referenced_relations = [
91
- Mongoid::Relations::Referenced::ManyToMany,
92
- Mongoid::Relations::Referenced::Many,
93
- Mongoid::Relations::Referenced::One,
94
- Mongoid::Relations::Referenced::In
91
+ Mongoid::Association::Referenced::HasAndBelongsToMany,
92
+ Mongoid::Association::Referenced::HasMany,
93
+ Mongoid::Association::Referenced::HasOne,
94
+ Mongoid::Association::Referenced::BelongsTo
95
95
  ]
96
96
 
97
97
  properties = Graphoid::Queries::Processor.children_of(selection)
@@ -1,3 +1,3 @@
1
1
  module Graphoid
2
- VERSION = '0.0.1'
2
+ VERSION = '0.0.2'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graphoid
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Maximiliano Perez Coto
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-06 00:00:00.000000000 Z
11
+ date: 2019-04-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails