Removing duplicated encoding of string types.