Fix NPE on serializing to JSON