Correcting all go vet errors
This commit is contained in:
@@ -37,7 +37,7 @@ func (a APIObjectVersioner) UpdateObject(obj runtime.Object, expiration *time.Ti
|
||||
return err
|
||||
}
|
||||
if expiration != nil {
|
||||
objectMeta.DeletionTimestamp = &util.Time{*expiration}
|
||||
objectMeta.DeletionTimestamp = &util.Time{Time: *expiration}
|
||||
}
|
||||
versionString := ""
|
||||
if resourceVersion != 0 {
|
||||
|
@@ -39,7 +39,7 @@ func TestObjectVersioner(t *testing.T) {
|
||||
if obj.ResourceVersion != "5" || obj.DeletionTimestamp != nil {
|
||||
t.Errorf("unexpected resource version: %#v", obj)
|
||||
}
|
||||
now := util.Time{time.Now()}
|
||||
now := util.Time{Time: time.Now()}
|
||||
obj = &TestResource{ObjectMeta: api.ObjectMeta{ResourceVersion: "a"}}
|
||||
if err := v.UpdateObject(obj, &now.Time, 5); err != nil {
|
||||
t.Fatalf("unexpected error: %v", err)
|
||||
|
@@ -107,7 +107,7 @@ func NewEtcdClientStartServerIfNecessary(server string) (tools.EtcdClient, error
|
||||
|
||||
type etcdHealth struct {
|
||||
// Note this has to be public so the json library can modify it.
|
||||
Health string `json:health`
|
||||
Health string `json:"health"`
|
||||
}
|
||||
|
||||
func EtcdHealthCheck(data []byte) error {
|
||||
|
@@ -181,8 +181,8 @@ func (w *etcdWatcher) translate() {
|
||||
case err := <-w.etcdError:
|
||||
if err != nil {
|
||||
w.emit(watch.Event{
|
||||
watch.Error,
|
||||
&api.Status{
|
||||
Type: watch.Error,
|
||||
Object: &api.Status{
|
||||
Status: api.StatusFailure,
|
||||
Message: err.Error(),
|
||||
},
|
||||
|
Reference in New Issue
Block a user