mirror of
https://github.com/restic/restic.git
synced 2026-11-19 23:01:08 +00:00
all: Minor cleanups
if x { return true } return false => return x
fmt.Sprintf("%v", x) => fmt.Sprint(x) or x.String()
The fmt.Sprintf idiom is still used in the SecretString tests, where it
serves security hardening.
This commit is contained in:
1 parent
d03460010f
commit
22147e1e02
5 files changed
+6
-10
No files matched your search
@@ -65,5 +65,5 @@ func (ids IDs) String() string {
|
||||
for _, id := range ids {
|
||||
elements = append(elements, shortID(id))
|
||||
}
|
||||
return fmt.Sprintf("%v", elements)
|
||||
return fmt.Sprint(elements)
|
||||
}
|
||||
Reference in new issue
Block a user