swaps out XHR and fixes log out when lose internet bug
Merge pull request #61 from waltzio/fix-no-internet-bug

Fixes issue where you get logged out when internet is gone