Skip to content

$file->getContent() return a StreamInterface instead of a String with GoogleCloudStorage adapter #652

Open
@laurentdabbb

Description

@laurentdabbb

Hi,

I use Gaufrette with GoogleCloudStorage adapter in production and local filesystem in development and I observe differences on the returned type of getContent() method of File object.

getContent calls Filesystem->read() which calls adaptater read() method.

Returned type of File->getContent() should be a string.
But, with GoogleCloudStorage adapter, the read() method return a StreamInterface ($response->getBody()) when Google_Http_Request does not exist (view here).

I suppose this line should be fixed with $response->getBody()->getContents()

Thx in advance.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions