Commit 7643ab7d authored by keven's avatar keven
Browse files

Fixed typo

parent 7d55aa96
......@@ -220,7 +220,7 @@ class Resource extends Entity implements ResourceInterface
public function file()
{
if (!$this->_file && $this->client && $this->hrefFile) {
$this->_file = $this->client->stream($this->hrefFile->href);
$this->_file = $this->client->file($this->hrefFile->href);
}
return $this->_file;
......
......@@ -72,6 +72,7 @@ verify_stream($stream, $id);
test('Cannot retrieve Stream via media() command.', function() use ($client, $stream) { try { $client->media($stream->href); return false; } catch (InvalidTypeException $e) { return true; }});
test('Publish in stream', $resource = $file->publishTo($stream));
test('Resource is instance of Resource', $resource instanceof Resource);
test('Resource file is instance of File', $resource->file() instanceof File);
test('Cannot retrieve Resource via stream() command.', function() use ($client, $resource) { try { $client->stream($resource->href); return false; } catch (InvalidTypeException $e) { return true; }});
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment