Skip to content

Commit e7c2b8e

Browse files
authored
Update SaveSettings for NS POV
1 parent 492fe1e commit e7c2b8e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Model/Observer/SaveSettings.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public function execute(Observer $observer)
6767
foreach ($storeIds as $storeId) {
6868
$indexName = $this->helper->getIndexName($this->productHelper->getIndexNameSuffix(), $storeId);
6969
$currentSettings = $this->algoliaHelper->getSettings($indexName);
70-
if (array_key_exists('replicas', $currentSettings)) {
70+
if (is_array($currentSettings) && array_key_exists('replicas', $currentSettings)) {
7171
$this->algoliaHelper->setSettings($indexName, ['replicas' => []]);
7272
$setReplicasTaskId = $this->algoliaHelper->getLastTaskId();
7373
$this->algoliaHelper->waitLastTask($indexName, $setReplicasTaskId);

0 commit comments

Comments
 (0)