meilisearch-rails 0.2.2 → 0.2.3

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: 9eae547864046ca0beb6cf7de6fa4458ff7449d9ba9c6d4ac4172d221cb8de3b
4
- data.tar.gz: acbed5cdbf3c63c68c39fef9d3e24620dd14ef5c47d6eabb5da7e96d57dd1a98
3
+ metadata.gz: dff716ea4a13c0f64718942f4988550a36076ae5dc52ac8ec7282000d116a99d
4
+ data.tar.gz: 1346eb18ddb24bf718693b7b3efa89d4b0084ecffe9f7ccae1d71956b3b8bf56
5
5
  SHA512:
6
- metadata.gz: a9b0017613ec9bf55fae9d4cb2e847a841d84078968a57d1940425e10ad5062ce747ee888837efd75b9b8826136dec52fd283759d05cbdaae7cc5b9eb237d1c7
7
- data.tar.gz: fd67c80baf0598425ef427ec50a6a849e736a704439e0eab67c29175979d4b69b26d1f15a97421ffec204a2dd047bc5f045dafd690e179c9a5eab2be05ab7b99
6
+ metadata.gz: 38e1657c75e4eec945502ead72001ba56dc194d3ce5217e65f40abc49de34312087aa30d401d342a15c4c0701f0d41d49faf8c94aef5cc40d79ed9bdc345f414
7
+ data.tar.gz: 2cd31c3b6b70fb4d2c38977870ab28256de22422c410280e7615e11dfe64dd8eaa98295c7bdf553655b427837b8864ee60930a0aafa39e8f1272af34210c0479
@@ -7,7 +7,8 @@ module MeiliSearch
7
7
  elsif Rails.application
8
8
  Rails.application.eager_load!
9
9
  end
10
- MeiliSearch.instance_variable_get :@included_in
10
+ klasses = MeiliSearch.instance_variable_get(:@included_in)
11
+ (klasses + klasses.map{ |klass| klass.descendants }.flatten).uniq
11
12
  end
12
13
 
13
14
  def clear_all_indexes
@@ -1,3 +1,3 @@
1
1
  module MeiliSearch
2
- VERSION = '0.2.2'
2
+ VERSION = '0.2.3'
3
3
  end
@@ -17,6 +17,12 @@ describe MeiliSearch::Utilities do
17
17
 
18
18
  meilisearch
19
19
  end
20
+
21
+ class DummyChild < Dummy
22
+ end
23
+
24
+ class DummyGrandChild < DummyChild
25
+ end
20
26
  end
21
27
 
22
28
  after(:each) do
@@ -24,7 +30,7 @@ describe MeiliSearch::Utilities do
24
30
  end
25
31
 
26
32
  it "should get the models where MeiliSearch module was included" do
27
- (MeiliSearch::Utilities.get_model_classes - [Dummy]).should == []
33
+ (MeiliSearch::Utilities.get_model_classes - [Dummy, DummyChild, DummyGrandChild]).should == []
28
34
  end
29
35
 
30
36
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: meilisearch-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Meili
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-08-24 00:00:00.000000000 Z
11
+ date: 2021-08-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json