Skip to content

Commit 89d174e

Browse files
committed
removeme: log how many mounts are set up
Signed-off-by: Salvatore Martire <4652631+salmart-dev@users.noreply.github.com>
1 parent 04973fc commit 89d174e

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

lib/private/Files/Mount/Manager.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
use OCP\Files\Mount\IMountManager;
1717
use OCP\Files\Mount\IMountPoint;
1818
use OCP\Files\NotFoundException;
19+
use Psr\Log\LoggerInterface;
1920

2021
class Manager implements IMountManager {
2122
/** @var MountPoint[] */
@@ -41,6 +42,14 @@ public function addMount(IMountPoint $mount) {
4142
$this->inPathCache->clear();
4243
}
4344

45+
public function __destruct() {
46+
$logger = \OC::$server->get(LoggerInterface::class);
47+
$logger->error(
48+
'Registered {count} mounts',
49+
['count' => \count($this->mounts)]
50+
);
51+
}
52+
4453
/**
4554
* @param string $mountPoint
4655
*/

0 commit comments

Comments
 (0)