catch the situation where network is not available