Encode all not None values.