Commit 0e3636b4ba0746bec0d2b1973f607db140ee5c9e

Authored by Andrew Kane
1 parent a4a258ef

Do not redefined methods in models for #366

Showing 1 changed file with 5 additions and 5 deletions   Show diff stats
lib/searchkick/model.rb
... ... @@ -77,23 +77,23 @@ module Searchkick
77 77  
78 78 def reindex
79 79 self.class.searchkick_index.reindex_record(self)
80   - end
  80 + end unless method_defined?(:reindex)
81 81  
82 82 def reindex_async
83 83 self.class.searchkick_index.reindex_record_async(self)
84   - end
  84 + end unless method_defined?(:reindex_async)
85 85  
86 86 def similar(options = {})
87 87 self.class.searchkick_index.similar_record(self, options)
88   - end
  88 + end unless method_defined?(:similar)
89 89  
90 90 def search_data
91 91 respond_to?(:to_hash) ? to_hash : serializable_hash
92   - end
  92 + end unless method_defined?(:search_data)
93 93  
94 94 def should_index?
95 95 true
96   - end
  96 + end unless method_defined?(:should_index?)
97 97  
98 98 end
99 99 end
... ...