Skip to content

Commit

Permalink
Update searchkick indexing for word_middle too
Browse files Browse the repository at this point in the history
  • Loading branch information
thekeenant authored Oct 24, 2024
1 parent 3aae6c8 commit 0530f10
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/course.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
class Course < ApplicationRecord
require 'csv'
self.primary_key = :uuid
searchkick text_middle: [:names, :uuid], synonyms: -> { CSV.read("#{Rails.root}/lib/course_synonyms.csv") }
searchkick word_middle: [:names, :uuid], synonyms: -> { CSV.read("#{Rails.root}/lib/course_synonyms.csv") }

def self.prepare_query(query)
if query.present?
Expand Down

0 comments on commit 0530f10

Please sign in to comment.