diff options
author | provokateurin <kate@provokateurin.de> | 2024-10-08 15:13:16 +0200 |
---|---|---|
committer | Kate <26026535+provokateurin@users.noreply.github.com> | 2024-10-23 13:24:18 +0200 |
commit | 0de4843b73ee4779c7e455dd80c36a6b506e0024 (patch) | |
tree | 67ad68f0b4c925a65b029bdfcaafe5681c527d3a /lib/private/Files/Storage/Local.php | |
parent | 74cd6e295a8e2e7c64e4fe38ba775986c57509a4 (diff) | |
download | nextcloud-server-refactor/storage/constructors.tar.gz nextcloud-server-refactor/storage/constructors.zip |
refactor(Storage): Align all Storage constructorsrefactor/storage/constructors
Signed-off-by: provokateurin <kate@provokateurin.de>
Diffstat (limited to 'lib/private/Files/Storage/Local.php')
-rw-r--r-- | lib/private/Files/Storage/Local.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/private/Files/Storage/Local.php b/lib/private/Files/Storage/Local.php index 9e3ec663f03..0b0272ce717 100644 --- a/lib/private/Files/Storage/Local.php +++ b/lib/private/Files/Storage/Local.php @@ -40,11 +40,11 @@ class Local extends \OC\Files\Storage\Common { protected bool $caseInsensitive = false; - public function __construct($arguments) { - if (!isset($arguments['datadir']) || !is_string($arguments['datadir'])) { + public function __construct(array $parameters) { + if (!isset($parameters['datadir']) || !is_string($parameters['datadir'])) { throw new \InvalidArgumentException('No data directory set for local storage'); } - $this->datadir = str_replace('//', '/', $arguments['datadir']); + $this->datadir = str_replace('//', '/', $parameters['datadir']); // some crazy code uses a local storage on root... if ($this->datadir === '/') { $this->realDataDir = $this->datadir; @@ -64,7 +64,7 @@ class Local extends \OC\Files\Storage\Common { // support Write-Once-Read-Many file systems $this->unlinkOnTruncate = $this->config->getSystemValueBool('localstorage.unlink_on_truncate', false); - if (isset($arguments['isExternal']) && $arguments['isExternal'] && !$this->stat('')) { + if (isset($parameters['isExternal']) && $parameters['isExternal'] && !$this->stat('')) { // data dir not accessible or available, can happen when using an external storage of type Local // on an unmounted system mount point throw new StorageNotAvailableException('Local storage path does not exist "' . $this->getSourcePath('') . '"'); |