Currently if the sync function fails for whatever reason (e.g. it can't get to the json dump of the membership database) it will still purge the old card and user data. This needs safeguards so that it keeps the latest state if it can't get the new db dump