Trying to figure out this error in my Ionic app for checking network connection. Im using ngCordova's network tools found here :
http://ngcordova.com/docs/plugins/network/
ngCordova claims that their $cordovaNetwork.isOnline() function works but I'm finding quite the opposite. $cordovaNetwork.getNetwork seems to work fine but otherwise, I am getting this error when executing console.log($cordovaNetwork.inOnline()); in the code.
I've seen answers to this issue elsewhere but none of them involve using this function. They involve using a states array or 'online/offline' events.
Can someone explain why isOnline() || isOffline() doesn't seem to work? How can I use this function accordingly without any circus tricks? I am debugging via Android. I am injecting properly and doing other things properly in the code. Any help is appreciated. Thanks.
