fixed problem on ios with null fields