handling offline mode, internet connection is not available