diff --git a/app/Repositories/MeiliSearchRepository.php b/app/Repositories/MeiliSearchRepository.php index 3b5c60f9..83e7f0c9 100644 --- a/app/Repositories/MeiliSearchRepository.php +++ b/app/Repositories/MeiliSearchRepository.php @@ -96,6 +96,9 @@ class MeiliSearchRepository extends BaseRepository public function import() { + if (!$this->isEnabled()) { + return 0; + } $client = $this->getClient(); $stats = $client->stats(); if (isset($stats['indexes'][self::INDEX_NAME])) { diff --git a/include/constants.php b/include/constants.php index 37608b46..e41a3150 100644 --- a/include/constants.php +++ b/include/constants.php @@ -1,6 +1,6 @@