SwiftLanguageWeather
SwiftLanguageWeather copied to clipboard
requestWhenInUseAuthorization issue
When stopped at the interface asking for WhenInUseAuthorization long enough, the app will not work until relaunch. I think the problem is caused by this func in LocationService.swift:
func requestLocation() {
locationManager.requestWhenInUseAuthorization()
locationManager.requestLocation()
}
@woyeyaowyy did you follow the step 4 in https://github.com/JakeLin/SwiftLanguageWeather#how-to-build? you need a key to run the app. Please let me know if you still have a problem, thanks.
Yes. The problem is when the app are asking for when-in-use-authorization, user stopped for a while and accept , app will not work until relaunch.