You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I use : mWiseFy.isDeviceConnectedToMobileOrWifiNetwork()
I have this error :
java.lang.NullPointerException: Attempt to invoke virtual method 'boolean android.net.NetworkInfo.isConnected()' on a null object reference
at com.isupatches.wisefy.WiseFy.isDeviceConnectedToMobileOrWifiNetwork(WiseFy.java:578)
It seem sometimes it's working and sometimes not...
The text was updated successfully, but these errors were encountered:
I can fix that one too with the next release...that's because for safety:
if (networkInfo.isConnected() && networkInfo.isAvailable()) {
should be:
if (networkInfo != null && networkInfo.isConnected() && networkInfo.isAvailable()) {
I bet in some cases networkInfo is null.
isuPatches
changed the title
mWiseFy.isDeviceConnectedToMobileOrWifiNetwork()
NullPointerException exception with isDeviceConnectedToMobileOrWifiNetwork()
Jul 4, 2017
Hi,
When I use :
mWiseFy.isDeviceConnectedToMobileOrWifiNetwork()
I have this error :
It seem sometimes it's working and sometimes not...
The text was updated successfully, but these errors were encountered: