Skip to content

Commit c6fe5e8

Browse files
authored
direct: Remove unnecessary error wrapping (#4157)
We already have "reading config" prefix at caller side. Noticed this error message: ``` Error: reading config: reading config: unsupported resource type: quality_monitors ```
1 parent 0f1bd8e commit c6fe5e8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

bundle/direct/bundle_plan.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -599,7 +599,7 @@ func (b *DeploymentBundle) makePlan(ctx context.Context, configRoot *config.Root
599599
},
600600
)
601601
if err != nil {
602-
return nil, fmt.Errorf("reading config: %w", err)
602+
return nil, err
603603
}
604604
}
605605
}
@@ -612,7 +612,7 @@ func (b *DeploymentBundle) makePlan(ctx context.Context, configRoot *config.Root
612612
prefix := "cannot plan " + node
613613
inputConfig, err := configRoot.GetResourceConfig(node)
614614
if err != nil {
615-
return nil, fmt.Errorf("%s: reading config: %s", prefix, err)
615+
return nil, err
616616
}
617617

618618
adapter, err := b.getAdapterForKey(node)

0 commit comments

Comments
 (0)