From 230ee7ac51f8a2de19944e151d298b77b7a0d264 Mon Sep 17 00:00:00 2001 From: Leandro Gehlen Date: Wed, 22 Apr 2026 07:51:33 -0300 Subject: [PATCH] Update tenant filtering logic for recently created models --- src/Listeners/UpdateSyncedResource.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Listeners/UpdateSyncedResource.php b/src/Listeners/UpdateSyncedResource.php index 40d4d644..f09437f3 100644 --- a/src/Listeners/UpdateSyncedResource.php +++ b/src/Listeners/UpdateSyncedResource.php @@ -82,7 +82,7 @@ class UpdateSyncedResource extends QueueableListener return $centralModel->tenants->filter(function ($model) use ($currentTenantMapping) { // Remove the mapping for the current tenant. - return ! $currentTenantMapping($model); + return ! $model->wasRecentlyCreated || ! $currentTenantMapping($model); }); }