From 0310488a22a4e39e7ca149881a2429cf210d588f Mon Sep 17 00:00:00 2001 From: Devin Beeuwkes Date: Mon, 31 Jan 2022 16:53:01 +0100 Subject: [PATCH] chore: update index initialization docs --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 52d620d..1681833 100644 --- a/README.md +++ b/README.md @@ -517,7 +517,7 @@ class MySidekiqWorker if remove # the record has likely already been removed from your database so we cannot # use ActiveRecord#find to load it - index = Algolia::Index.new("index_name") + index = AlgoliaSearch.client.init_index("index_name") index.delete_object(id) else # the record should be present @@ -550,7 +550,7 @@ class MySidekiqWorker if remove # the record has likely already been removed from your database so we cannot # use ActiveRecord#find to load it - index = Algolia::Index.new("index_name") + index = AlgoliaSearch.client.init_index("index_name") index.delete_object(id) else # the record should be present