double.NaN is not very compatible with json