【发布时间】:2018-05-12 23:08:41
【问题描述】:
我指的是以下代码将文件上传到 Google Cloud Storage https://github.com/GoogleCloudPlatform/nodejs-getting-started/blob/master/3-binary-data/lib/images.js#L48
我能够成功上传,现在我正在尝试将元数据添加到文件中,所以我修改了如下代码
const stream = file.createWriteStream({
metadata: {
contentType: req.file.mimetype,
foo: 'bar'
}
});
但 foo=bar 元数据未附加到 Google Cloud Storage 中的文件
【问题讨论】:
标签: node.js google-cloud-platform google-cloud-storage