the following code
uaString := "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko)" // macbook telegram
ua := useragent.Parse(uaString)
fmt.Printf("%+v\n", ua)
produces output:
{VersionNo:{Major:0 Minor:0 Patch:0} OSVersionNo:{Major:10 Minor:15 Patch:7} URL: String:Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Name:Intel Mac OS X 10_15_7 Version: OS:macOS OSVersion:10.15.7 Device: Mobile:false Tablet:false Desktop:true Bot:false}
It seems strange that Name:"Intel Mac OS X 10_15_7" whereas VersionNo:{Major:0 Minor:0 Patch:0} .
I mean the Name seems should include the browser name only (the brand) without version. if it is not detectable probably "Unknown" is the good value, but in this particular case I would say it should be something like "Apple WebView".
So my question is - what is concept behind the Name attribute, and does it align with the example I provided ?
the following code
produces output:
It seems strange that Name:"Intel Mac OS X 10_15_7" whereas VersionNo:{Major:0 Minor:0 Patch:0} .
I mean the Name seems should include the browser name only (the brand) without version. if it is not detectable probably "Unknown" is the good value, but in this particular case I would say it should be something like "Apple WebView".
So my question is - what is concept behind the Name attribute, and does it align with the example I provided ?