Fix crash in username json serialization