blob: 2e0645e092a5e43a6de051a45c6a5e204fa2ddfc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
<?php
declare(strict_types=1);
/**
* SPDX-FileCopyrightText: 2020 Nextcloud GmbH and Nextcloud contributors
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
namespace OC\Files\Storage;
use OC\Files\Cache\LocalRootScanner;
use OCP\Files\Cache\IScanner;
use OCP\Files\Storage\IStorage;
class LocalRootStorage extends Local {
public function getScanner(string $path = '', ?IStorage $storage = null): IScanner {
if (!$storage) {
$storage = $this;
}
return $storage->scanner ?? ($storage->scanner = new LocalRootScanner($storage));
}
}
|