From 7cdccd058f98a5e4164fc314f06f62fd8dfcd73c Mon Sep 17 00:00:00 2001 From: provokateurin Date: Thu, 19 Sep 2024 18:19:34 +0200 Subject: fix(Storage): Fix IStorage return types Signed-off-by: provokateurin --- lib/private/Files/Storage/Home.php | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) (limited to 'lib/private/Files/Storage/Home.php') diff --git a/lib/private/Files/Storage/Home.php b/lib/private/Files/Storage/Home.php index fd1d287629f..6729b293860 100644 --- a/lib/private/Files/Storage/Home.php +++ b/lib/private/Files/Storage/Home.php @@ -8,6 +8,8 @@ namespace OC\Files\Storage; use OC\Files\Cache\HomePropagator; +use OCP\Files\Cache\ICache; +use OCP\Files\Cache\IPropagator; use OCP\IUser; /** @@ -38,41 +40,31 @@ class Home extends Local implements \OCP\Files\IHomeStorage { parent::__construct(['datadir' => $datadir]); } - public function getId() { + public function getId(): string { return $this->id; } - /** - * @return \OC\Files\Cache\HomeCache - */ - public function getCache($path = '', $storage = null) { + public function getCache($path = '', $storage = null): ICache { if (!$storage) { $storage = $this; } if (!isset($this->cache)) { $this->cache = new \OC\Files\Cache\HomeCache($storage, $this->getCacheDependencies()); } - /** @var \OC\Files\Cache\HomeCache */ return $this->cache; } - public function getPropagator($storage = null) { + public function getPropagator($storage = null): IPropagator { if (!$storage) { $storage = $this; } if (!isset($this->propagator)) { $this->propagator = new HomePropagator($storage, \OC::$server->getDatabaseConnection()); } - /** @var \OC\Files\Cache\Propagator */ return $this->propagator; } - /** - * Returns the owner of this home storage - * - * @return \OC\User\User owner of this home storage - */ public function getUser(): IUser { return $this->user; } -- cgit v1.2.3