updated to only update when ip changes