user_agent
user_agent copied to clipboard
Browser type exported (public), does it need to be?
Description
I found this library (appreciate your OSS contribution) and was looking thru the GoDoc to gain an understanding of the package's API structure.
I was wondering about the Browser
type. It's part of the public API, it doesn't seem to be exposed by any of the public functions or as a public field of the other exported types. To me, it appears that this type should not be exported, and should be renamed from Browser
to browser
.
It's also possible that perhaps that the receiver method:
func (p *UserAgent) Browser() (string, string)
Should instead be exposed as:
func (p *UserAgent) Browser() Browser
What do you think?