Refine WiFi lock handling.