acknowledge that creation of a restmapper can fail and that we cannot have a default
This commit is contained in:
@@ -389,7 +389,10 @@ func RunCreateSubcommand(f cmdutil.Factory, options *CreateSubcommandOptions) er
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
mapper := f.RESTMapper()
|
||||
mapper, err := f.RESTMapper()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if !options.DryRun {
|
||||
// create subcommands have compiled knowledge of things they create, so type them directly
|
||||
gvks, _, err := legacyscheme.Scheme.ObjectKinds(obj)
|
||||
|
Reference in New Issue
Block a user