Skip to content

Commit

Permalink
fix: don't move the main instance
Browse files Browse the repository at this point in the history
  • Loading branch information
thorsten committed Jul 26, 2024
1 parent 4217b5c commit 04b5e0f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion phpmyfaq/admin/instances.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@
$system = new System();
$updatedClient = new Client($faqConfig);
$moveInstance = false;
$instance->setId($instanceId);

// Collect updated data for database
$updatedData = new InstanceEntity();
Expand All @@ -80,7 +81,7 @@
// Original data
$originalData = $currentClient->getInstanceById($instanceId);

if ($originalData->url !== $updatedData->getUrl()) {
if ($originalData->url !== $updatedData->getUrl() && !$instance->getConfig('isMaster')) {
$moveInstance = true;
}

Expand Down

0 comments on commit 04b5e0f

Please sign in to comment.