treewide: cleanup error string formatting
Change-Id: I9012ba58dded916984468219b214200144a439b9
Reviewed-on: https://review.monogon.dev/c/monogon/+/3023
Reviewed-by: Serge Bazanski <serge@monogon.tech>
Vouch-Run-CI: Tim Windelschmidt <tim@monogon.tech>
Tested-by: Jenkins CI
diff --git a/cloud/shepherd/manager/initializer.go b/cloud/shepherd/manager/initializer.go
index 2c04c43..a380a8f 100644
--- a/cloud/shepherd/manager/initializer.go
+++ b/cloud/shepherd/manager/initializer.go
@@ -263,10 +263,10 @@
return nil, fmt.Errorf("agent returned unknown result of type %T", arsp.Result)
}
if !proto.Equal(&imsg, successResp.InitMessage) {
- return nil, fmt.Errorf("agent did not send back the init message.")
+ return nil, fmt.Errorf("agent did not send back the init message")
}
if len(successResp.Key) != ed25519.PublicKeySize {
- return nil, fmt.Errorf("agent key length mismatch.")
+ return nil, fmt.Errorf("agent key length mismatch")
}
klog.Infof("Started the agent (machine ID: %s, key: %s).", mid, hex.EncodeToString(successResp.Key))
return successResp.Key, nil