特定の言葉を含む投稿をすぐに検索できるようにしたい
特定の言葉をページに残しておいて、その言葉をクリックすればその言葉を含む投稿を表示できるようにしたい。
発生している問題・エラーメッセージ
NoMethodError in WordsController#pins undefined method `pluck' for #<Word id: 1, content: "test"
該当のソースコード
ruby
1def pins 2 @feed = Word.find_by(id: params[:id]) 3 @keyword = @feed.pluck(:content) 4 @books = Blog.where("content LIKE ?", "%#{@keyword}%") 5end
html
1<div id="blogs"> 2 <% @books.each do |blog| %> 3 <%= render blog %> 4 <p> 5 <%= link_to "Show this blog", blog %> 6 </p> 7 <% end %> 8</div>
補足情報(FW/ツールのバージョンなど)
Rails versionのバージョンは7.0.5です。
他に必要なところがあれば教えてください。

下記のような回答は推奨されていません。
このような回答には修正を依頼しましょう。
また依頼した内容が修正された場合は、修正依頼を取り消すようにしましょう。