wrapping unmarshal with check for nil again