Skip to content

Commit 9534b77

Browse files
committed
chore(ci): update golangci-lint config for new more assertive staticchecks
1 parent 731377e commit 9534b77

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

.golangci.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,14 @@ linters:
2828
- third_party$
2929
- builtin$
3030
- examples$
31+
settings:
32+
staticcheck:
33+
checks:
34+
- all
35+
# disable these:
36+
- -QF1008
37+
- -ST1003
38+
3139
issues:
3240
max-same-issues: 0
3341
formatters:

internal/provider/branch_resource.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ func (r *branchResource) Create(ctx context.Context, req resource.CreateRequest,
260260
Name: name.ValueString(),
261261
ParentBranch: *parentBranch,
262262
}
263-
if !(data.RestoredFromBranch.IsNull() || data.RestoredFromBranch.IsUnknown()) {
263+
if !data.RestoredFromBranch.IsNull() && !data.RestoredFromBranch.IsUnknown() {
264264
var rfb restoredFromBranchResource
265265
resp.Diagnostics.Append(data.RestoredFromBranch.As(ctx, &rfb, basetypes.ObjectAsOptions{})...)
266266
if resp.Diagnostics.HasError() {

0 commit comments

Comments
 (0)