dont return private storage interface from public mount interface

Signed-off-by: Robin Appelman <robin@icewind.nl>
pull/25392/head
Robin Appelman 2021-01-29 16:16:03 +07:00
parent a219fa587a
commit 7995c6e1dc
No known key found for this signature in database
GPG Key ID: 42B69D8A64526EFB
6 changed files with 7 additions and 10 deletions

@ -369,11 +369,6 @@ class SharedStorage extends \OC\Files\Storage\Wrapper\Jail implements ISharedSto
return $this->superShare->getNodeType();
}
/**
* @param string $path
* @param null $storage
* @return Cache
*/
public function getCache($path = '', $storage = null) {
if ($this->cache) {
return $this->cache;

@ -38,7 +38,7 @@ interface Storage extends \OCP\Files\Storage {
* get a cache instance for the storage
*
* @param string $path
* @param \OC\Files\Storage\Storage (optional) the storage to pass to the cache
* @param \OC\Files\Storage\Storage|null (optional) the storage to pass to the cache
* @return \OC\Files\Cache\Cache
*/
public function getCache($path = '', $storage = null);

@ -396,7 +396,7 @@ class Jail extends Wrapper {
* get a cache instance for the storage
*
* @param string $path
* @param \OC\Files\Storage\Storage (optional) the storage to pass to the cache
* @param \OC\Files\Storage\Storage|null (optional) the storage to pass to the cache
* @return \OC\Files\Cache\Cache
*/
public function getCache($path = '', $storage = null) {

@ -386,7 +386,7 @@ class Wrapper implements \OC\Files\Storage\Storage, ILockingStorage, IWriteStrea
* get a cache instance for the storage
*
* @param string $path
* @param \OC\Files\Storage\Storage (optional) the storage to pass to the cache
* @param \OC\Files\Storage\Storage|null (optional) the storage to pass to the cache
* @return \OC\Files\Cache\Cache
*/
public function getCache($path = '', $storage = null) {

@ -48,7 +48,7 @@ interface IMountPoint {
/**
* Get the storage that is mounted
*
* @return \OC\Files\Storage\Storage
* @return \OCP\Files\Storage\IStorage
* @since 8.0.0
*/
public function getStorage();

@ -433,10 +433,12 @@ interface IStorage {
public function getOwner($path);
/**
* @param string $path
* @param IStorage|null $storage
* @return ICache
* @since 9.0.0
*/
public function getCache();
public function getCache($path = '', $storage = null);
/**
* @return IPropagator