Skip to content

Commit

Permalink
chore: fix linter false positive
Browse files Browse the repository at this point in the history
Apply a workaround for the false positive for GO-S2307.
  • Loading branch information
stevenh committed Jul 10, 2024
1 parent e7565ae commit 1602587
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugin.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func pluginFunc(cmd *cobra.Command, _ []string) error {
return err
}

defer f.Close() //nolint:errcheck // Read only file so We would have returned an error before if this failed.
defer func() { _ = f.Close() }() // Workaround false positive for GO-S2307.

desc, err := plugin.Describe(f, goVersion, libcVersion)
if err != nil {
Expand Down

0 comments on commit 1602587

Please sign in to comment.