The source project of this merge request has been removed.
Handle error better and retrieve location only if success
Previously if error occurred, location is still extracted, resulting in wrong latitude and longitude.
Also, besides BDLocation.TypeOffLineLocation, BDLocation.TypeNetWorkLocation is also a successful location query
Closes: #2