fix: conflict import name with variable

`template` is an import in `cobra.go` file and also used as a variable
name, which masks the library in the scope of that function.
This commit is contained in:
Yash Ladha 2022-12-15 08:55:57 +05:30
parent 923592041e
commit 792ea41ef7

View file

@ -167,8 +167,8 @@ func appendIfNotPresent(s, stringToAppend string) string {
// rpad adds padding to the right of a string.
func rpad(s string, padding int) string {
template := fmt.Sprintf("%%-%ds", padding)
return fmt.Sprintf(template, s)
formattedString := fmt.Sprintf("%%-%ds", padding)
return fmt.Sprintf(formattedString, s)
}
// tmpl executes the given template text on data, writing the result to w.