From b9b1ec1b64c6a073d97eb5f63364c60c9c86cd03 Mon Sep 17 00:00:00 2001 From: Prem Palanisamy Date: Thu, 26 Feb 2026 07:49:58 +0000 Subject: [PATCH] fix: respect include inactive deployments option Use the resources array to determine whether to export only the active deployment or all deployments. When deployment/site-deployment resource type is included, export all deployments instead of only the active one. --- src/Migration/Sources/Appwrite.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/Migration/Sources/Appwrite.php b/src/Migration/Sources/Appwrite.php index 47a0346118..a2edd3a2de 100644 --- a/src/Migration/Sources/Appwrite.php +++ b/src/Migration/Sources/Appwrite.php @@ -1518,9 +1518,8 @@ class Appwrite extends Source } try { - if (\in_array(Resource::TYPE_DEPLOYMENT, $resources)) { - $this->exportDeployments($batchSize, true); - } + $exportOnlyActive = !\in_array(Resource::TYPE_DEPLOYMENT, $resources); + $this->exportDeployments($batchSize, $exportOnlyActive); } catch (\Throwable $e) { $this->addError(new Exception( Resource::TYPE_DEPLOYMENT, @@ -1549,9 +1548,8 @@ class Appwrite extends Source } try { - if (\in_array(Resource::TYPE_SITE_DEPLOYMENT, $resources)) { - $this->exportSiteDeployments($batchSize, true); - } + $exportOnlyActive = !\in_array(Resource::TYPE_SITE_DEPLOYMENT, $resources); + $this->exportSiteDeployments($batchSize, $exportOnlyActive); } catch (\Throwable $e) { $this->addError(new Exception( Resource::TYPE_SITE_DEPLOYMENT,