Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
4.1.1
-
None
-
None
-
Android
Description
This bug affects release 1.1.0 of the network infomation plugin. Release 1.0.1 is not affected.
navigator.connection.type gives "unknown" as a result when connected via 3G. It probably gives "unknown" as a result in other cases.
This bug, you can see easily, was introduced with commit 6550b937d0d437183984437deb452cbdd653ac18 of NetworkManager.java by SidFerreira's commit on 28 July ("Performance-related fix").
The cause of the bug introduced is that line 247 misses a conversion of the subtypename to lower case, so
type = info.getSubtypeName();
should instead be
type = info.getSubtypeName().toLowerCase(US);
to compare correctly.
By the way, in line 243
else if (type.toLowerCase().equals(TYPE_ETHERNET)) {
toLowerCase() can be omitted because type is already in lower case.
Attachments
Issue Links
- is a clone of
-
CB-10160 Android - ConnectionType always returning Connection.UNKNOWN
- Closed