Updated check for internet access