File tree Expand file tree Collapse file tree 2 files changed +1
-7
lines changed Expand file tree Collapse file tree 2 files changed +1
-7
lines changed Original file line number Diff line number Diff line change @@ -87,7 +87,7 @@ func FixTabsOrDie(in typed.YAMLObject) typed.YAMLObject {
87
87
88
88
func (s * State ) checkInit () error {
89
89
if s .Live == nil {
90
- obj , err := s .Parser .New ( )
90
+ obj , err := s .Parser .FromYAML ( "{}" )
91
91
if err != nil {
92
92
return fmt .Errorf ("failed to create new empty object: %v" , err )
93
93
}
Original file line number Diff line number Diff line change @@ -87,12 +87,6 @@ func (p *ParseableType) IsValid() bool {
87
87
return ok
88
88
}
89
89
90
- // New returns a new empty object with the current schema and the
91
- // type "typename".
92
- func (p * ParseableType ) New () (TypedValue , error ) {
93
- return p .FromYAML (YAMLObject ("{}" ))
94
- }
95
-
96
90
// FromYAML parses a yaml string into an object with the current schema
97
91
// and the type "typename" or an error if validation fails.
98
92
func (p * ParseableType ) FromYAML (object YAMLObject ) (TypedValue , error ) {
You can’t perform that action at this time.
0 commit comments