I have local database which has the field "distance" which is based on user's current location. so i have added a logic to update database if there is change in location for every 30sec.
If there is change in the location one time in 30 sec its working fine, but when the device location changes to more to one location within 30 sec, database updated distance is changing.
Can you please let me know whats the mistake i have done here.