Skip to content
This repository has been archived by the owner on Feb 17, 2023. It is now read-only.

A mobile user agent is reported as a non-mobile user agent. #75

Open
gaojunhuicavon opened this issue Dec 24, 2020 · 0 comments
Open

A mobile user agent is reported as a non-mobile user agent. #75

gaojunhuicavon opened this issue Dec 24, 2020 · 0 comments
Assignees
Labels

Comments

@gaojunhuicavon
Copy link

Description

The following ua containing the keyword iPhone wants to be reported as a mobile ua:

Mozilla/5.0 (iPhone; CPU iPhone OS 13_6 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Jike/7.6.7 /sa-sdk-ios/sensors-verify/track.midway.run?jike

Steps to reproduce

import "github.com/mssola/user_agent"

func main() {
	ua := "Mozilla/5.0 (iPhone; CPU iPhone OS 13_6 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Jike/7.6.7 /sa-sdk-ios/sensors-verify/track.midway.run?jike"
	user_agent.New(ua).Mobile() // True is expected, but false is got.
}

user_agent version

v0.5.2

Go version and interpreter

go version go1.14.2 darwin/amd64

Operating system

macOS Mojave 10.14.6(18G6032)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants