Modified swift handling to explicitly set 404 responses to false

This commit is contained in:
Daniel Tosello 2016-01-12 16:47:52 +11:00
parent 41f1feaf23
commit 8783eb99f7
1 changed files with 2 additions and 1 deletions

View File

@ -323,7 +323,8 @@ class Swift extends \OC\Files\Storage\Common {
$streamInterface->rewind();
$stream = $streamInterface->getStream();
stream_context_set_option($stream, 'swift','content', $streamInterface);
if(is_resource($stream)) {
if(!strrpos($streamInterface
->getMetaData('wrapper_data')[0], '404 Not Found')) {
return $stream;
}
return false;