Fixed bugs about wifi/bluetooth scanning :-((((((