added restore functionality to get rid of outdated callbacks