Change URI to IRI after finding validation pattern
This commit is contained in:
@@ -10,7 +10,7 @@ type Category struct {
|
||||
*CommonAttributes
|
||||
Content Content `xml:"content"` // undefinedContent in RFC4287
|
||||
Term string `xml:"term,attr"`
|
||||
Scheme URI `xml:"scheme,attr,omitempty"`
|
||||
Scheme IRI `xml:"scheme,attr,omitempty"`
|
||||
Label string `xml:"label,attr,omitempty"`
|
||||
}
|
||||
|
||||
@@ -33,7 +33,7 @@ func (c *Category) Check() error {
|
||||
}
|
||||
|
||||
if c.Scheme != "" {
|
||||
if !isValidURI(c.Scheme) {
|
||||
if !isValidIRI(c.Scheme) {
|
||||
return fmt.Errorf("scheme attribute %v of category not correctly formatted", c.Scheme)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user