remove []byte trans, handle func error

This commit is contained in:
yuzhiquan 2019-11-28 19:26:45 +08:00
parent 7cc0110081
commit 24869ddf21
2 changed files with 3 additions and 3 deletions

View File

@ -197,7 +197,7 @@ func getPrivateRegistries(ctx context.Context, cfg *config.Node) (*templates.Reg
return nil, err return nil, err
} }
logrus.Infof("Using registry config file at %s", cfg.AgentConfig.PrivateRegistry) logrus.Infof("Using registry config file at %s", cfg.AgentConfig.PrivateRegistry)
if err := yaml.Unmarshal([]byte(privRegistryFile), &privRegistries); err != nil { if err := yaml.Unmarshal(privRegistryFile, &privRegistries); err != nil {
return nil, err return nil, err
} }
return privRegistries, nil return privRegistries, nil

View File

@ -246,8 +246,8 @@ func (entry *Entry) Del() error {
if err != nil { if err != nil {
return err return err
} }
entry.Set.Parent.Save()
return nil return entry.Set.Parent.Save()
} }
// Test wether an entry is in a set or not. Exit status number is zero if the // Test wether an entry is in a set or not. Exit status number is zero if the