Skip to content

Commit

Permalink
Only return a detaied diff if a diff is detected
Browse files Browse the repository at this point in the history
  • Loading branch information
VenelinMartinov committed Dec 16, 2024
1 parent 03234db commit ed84692
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions pkg/tfbridge/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -1175,13 +1175,13 @@ func (p *Provider) Diff(ctx context.Context, req *pulumirpc.DiffRequest) (*pulum
changes = pulumirpc.DiffResponse_DIFF_NONE
} else {
changes = pulumirpc.DiffResponse_DIFF_SOME
}

replaceDecision := diff.RequiresNew()
detailedDiff, err = makeDetailedDiffV2(
ctx, schema, fields, res.TF, p.tf, state, diff, assets, p.supportsSecrets, news, &replaceDecision)
if err != nil {
return nil, err
replaceDecision := diff.RequiresNew()
detailedDiff, err = makeDetailedDiffV2(
ctx, schema, fields, res.TF, p.tf, state, diff, assets, p.supportsSecrets, news, &replaceDecision)
if err != nil {
return nil, err
}
}
} else {
dd := makeDetailedDiffExtra(ctx, schema, fields, olds, news, diff)
Expand Down

0 comments on commit ed84692

Please sign in to comment.