I'd guess that it also remembers the SSID from the wifi, and uses that as a validation step against the IP address.