Skip to content

Commit

Permalink
Import dependent schema only when there is schemaLocation set-up
Browse files Browse the repository at this point in the history
  • Loading branch information
isimluk committed May 28, 2020
1 parent 7b913db commit f3db978
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/xsd/schema.go
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,8 @@ type Import struct {
}

func (i *Import) load(ws *Workspace, baseDir string) (err error) {
i.ImportedSchema, err = ws.loadXsd(filepath.Join(baseDir, i.SchemaLocation))
if i.SchemaLocation != "" {
i.ImportedSchema, err = ws.loadXsd(filepath.Join(baseDir, i.SchemaLocation))
}
return
}

0 comments on commit f3db978

Please # to comment.