strapi-plugin-meilisearch
strapi-plugin-meilisearch copied to clipboard
Unpublishing content type entry does not remove index unless you manually update it
Description
Unpublishing a content type entry via the official Draft/Publish plugin causes an inconsistent behavior with the Meilisearch plugin.
Unpublishing does not remove the entry from the index, unless the whole index is manually refreshed via the plugin's page.
Publishing the entry does automatically add it, so this can not be solved with a publicationState
property or similar.
Expected behavior Upon pressing the Unpublish button, the index for that entry should be automatically removed.
Current behavior Unpublishing an entry does not remove it remove it from the index automatically. When accessing the Meilisearch plugin page the indexed number of documents exceed the number of total documents (as seen in the screenshot below). This is not just a visual bug, the index is actually there.
Screenshots or Logs
Environment (please complete the following information):
- OS: Windows 10 64-bit
- MeiliSearch version: v0.24.0
- strapi-plugin-meilisearch version: 0.4.1
- Browser: Google Chrome Version 97.0.4692.71/
- Strapi version: v3.6.8
- Node version: 12.20.1
Hey @Tocas97
You are absolutely right. I forgot to add a listener to the unpublish
action. Let me add that to the important features to add
Sorry, this issue is not fixed yet. Tested on version 0.6.6.
Hey @vietlongn I did not realize you were using strapi v3! The fix has been introduced in the plugin compatible with strapi v4.
Since there are a lot of users still using strapi v3, could you upvote this ?
https://github.com/meilisearch/strapi-plugin-meilisearch/issues/444
Since v3 is not used a lot, this issue might not be relevant anymore. closing this. Feel free to re-open if it is still needed