From a70d241da049abead910561f0b9bff06fca68e65 Mon Sep 17 00:00:00 2001 From: Hemachandar Date: Tue, 24 Mar 2026 16:37:31 +0530 Subject: [PATCH] fix path trigger --- .../Modules/VCS/Http/GitHub/Deployment.php | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/Appwrite/Platform/Modules/VCS/Http/GitHub/Deployment.php b/src/Appwrite/Platform/Modules/VCS/Http/GitHub/Deployment.php index 3f39ac9018..c30f960262 100644 --- a/src/Appwrite/Platform/Modules/VCS/Http/GitHub/Deployment.php +++ b/src/Appwrite/Platform/Modules/VCS/Http/GitHub/Deployment.php @@ -576,9 +576,17 @@ trait Deployment return false; } - $pathTrigger = new BuildTrigger($resource->getAttribute('providerPaths', [])); - foreach ($providerAffectedFiles as $file) { - if (!$pathTrigger->isValid($file)) { + $providerPaths = $resource->getAttribute('providerPaths', []); + if (!empty($providerPaths) && !empty($providerAffectedFiles)) { + $pathTrigger = new BuildTrigger($providerPaths); + $pathMatched = false; + foreach ($providerAffectedFiles as $file) { + if ($pathTrigger->isValid($file)) { + $pathMatched = true; + break; + } + } + if (!$pathMatched) { Span::add("{$logBase}.build.skipped.reason", 'path'); return false; }