fix order of connecting wifi