This should fix the unregistering bug.