Make NewLogo more flexible
This commit is contained in:
6
logo.go
6
logo.go
@@ -3,8 +3,6 @@ package atom
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
|
||||
"github.com/google/uuid"
|
||||
)
|
||||
|
||||
type Logo struct {
|
||||
@@ -13,8 +11,8 @@ type Logo struct {
|
||||
}
|
||||
|
||||
// NewLogo creates a new Logo. It returns a *Logo.
|
||||
func NewLogo() *Logo {
|
||||
return &Logo{URI: IRI(fmt.Sprint("urn:uuid:", uuid.New()))}
|
||||
func NewLogo(uri string) *Logo {
|
||||
return &Logo{URI: IRI(uri)}
|
||||
}
|
||||
|
||||
// Check checks the Logo for incompatibilities with RFC4287. It returns an
|
||||
|
Reference in New Issue
Block a user