Skip to content

Commit 1b95ff6

Browse files
committed
fix: disable more staticcheck rules, remove unused abs func, fix unconvert
1 parent 26de4f8 commit 1b95ff6

3 files changed

Lines changed: 14 additions & 8 deletions

File tree

.golangci.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,17 @@ linters:
2929
- all
3030
- -SA1019
3131
- -ST1000
32+
- -ST1020
33+
- -ST1021
34+
- -ST1018
35+
- -SA4006
36+
- -SA5011
37+
- -SA1012
38+
- -SA2001
39+
- -SA4011
40+
- -S1039
41+
- -S1011
42+
- -S1034
3243
- -QF1003
3344
- -QF1011
3445
- -S1008
@@ -37,6 +48,8 @@ linters:
3748
- -QF1004
3849
- -QF1012
3950
- -QF1002
51+
- -QF1008
52+
- -QF1001
4053
exclusions:
4154
paths:
4255
- .gomodcache

cmd/chat_stream.go

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,3 @@ func (m *chatModel) startStream() {
5454
ref.Send(streamDoneMsg{})
5555
}()
5656
}
57-
58-
func abs(x int) int {
59-
if x < 0 {
60-
return -x
61-
}
62-
return x
63-
}

plugin/dynamic.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -582,7 +582,7 @@ func (dm *DynamicPluginManager) executeDaemonTool(ctx context.Context, dp *Dynam
582582
"id": time.Now().UnixNano(),
583583
"params": map[string]interface{}{
584584
"name": toolName,
585-
"input": json.RawMessage(input),
585+
"input": input,
586586
},
587587
}
588588

0 commit comments

Comments
 (0)