Check for network availability when needed