From 09038e204e539569be0b9486cd84d786da32e16c Mon Sep 17 00:00:00 2001 From: Kemal Hadimli Date: Mon, 23 May 2022 09:11:52 +0100 Subject: [PATCH] chore: Revert cleanup-stale-data filter change From https://github.com/cloudquery/cq-provider-sdk/pull/265 --- provider/execution/execution.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/provider/execution/execution.go b/provider/execution/execution.go index 55c374ac..e13fdac1 100644 --- a/provider/execution/execution.go +++ b/provider/execution/execution.go @@ -270,10 +270,8 @@ func (e TableExecutor) callTableResolve(ctx context.Context, client schema.Clien e.Logger.Info("fetched successfully", "count", nc) } - if !diags.HasErrors() { - if err := e.cleanupStaleData(ctx, client, parent); err != nil { - return nc, diags.Add(fromError(err, diag.WithType(diag.DATABASE), diag.WithSummary("failed to cleanup stale data on table %q", e.Table.Name))) - } + if err := e.cleanupStaleData(ctx, client, parent); err != nil { + return nc, diags.Add(fromError(err, diag.WithType(diag.DATABASE), diag.WithSummary("failed to cleanup stale data on table %q", e.Table.Name))) } return nc, diags