Skip to content

Commit

Permalink
Remove unnecessary fmt.Sprintf (#1836)
Browse files Browse the repository at this point in the history
  • Loading branch information
RebeccaMahany authored Aug 14, 2024
1 parent 3404ab6 commit a80efbf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/packaging/fetch.go
Original file line number Diff line number Diff line change
Expand Up @@ -198,5 +198,5 @@ func getReleaseVersionFromTufRepo(binaryName, channel, platform, arch string) (s
targetFilename := filepath.Base(custom.Target)

// Target looks like <binary>-<version>.tar.gz -- strip off extension and binary name to get version
return strings.TrimSuffix(strings.TrimPrefix(targetFilename, fmt.Sprintf(binaryName+"-")), ".tar.gz"), nil
return strings.TrimSuffix(strings.TrimPrefix(targetFilename, binaryName+"-"), ".tar.gz"), nil
}

0 comments on commit a80efbf

Please sign in to comment.