Closed
Description
In my project i want to create an empty file in google storage with metadata
in one step.
I found this note in gcloud-node/lib/storage/file.js
:
...
* @param {object=} metadata - Metadata to set on the object. This is useful
* when you are creating a file for the first time, to prevent making an
* extra call to `setMetadata`.
...
function File(bucket, name, metadata) { }
But i cant find any code that use file.metadata
parameter in createWriteStream
or getWritableStream_
.
Also storage.bucket.file(name)
method that created new instance of File
not contains metadata
parameter.
I know, that i can use createWriteStream(metadata)
. This is the only way?