{
MESSAGE = LoginWelcomeBackMessage;
SUCCESS = 1;
USER = {
AcceptAllFriendRequests = 0;
CreateDate = "June, 07 2010 00:00:00";
DayOfBirth = "April, 24 1974 00:00:00";
UserName = "Erik Madsen";
};
}
My CFC defines all the columns in my database table, but when a column is NULL, the field isn’t returned as a property in the JSON? The example above should have PersonalInfo = “”; Is there a way to force it to return an empty string?
Simply leaving the property out is probably closer to
nullthan an empty string in most circumstances. if you want an empty string you should return an empty string. how a null value is treated depends on your serializer.In javascript, the official implementation handles it quite fine: