actually make segment transformation null safe