mirror of
https://github.com/HaschekSolutions/pictshare.git
synced 2025-11-18 22:18:00 +00:00
S3/Minio storage controller Support
This commit is contained in:
22
storage-controllers/s3/GuzzleHttp/Psr7/NoSeekStream.php
Normal file
22
storage-controllers/s3/GuzzleHttp/Psr7/NoSeekStream.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
namespace GuzzleHttp\Psr7;
|
||||
|
||||
use Psr\Http\Message\StreamInterface;
|
||||
|
||||
/**
|
||||
* Stream decorator that prevents a stream from being seeked
|
||||
*/
|
||||
class NoSeekStream implements StreamInterface
|
||||
{
|
||||
use StreamDecoratorTrait;
|
||||
|
||||
public function seek($offset, $whence = SEEK_SET)
|
||||
{
|
||||
throw new \RuntimeException('Cannot seek a NoSeekStream');
|
||||
}
|
||||
|
||||
public function isSeekable()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user