mirror of
https://github.com/nextcloud/server.git
synced 2026-02-20 00:12:30 -05:00
Only do all the "find path" magic when we need to register them
This commit is contained in:
parent
e38dea3542
commit
9c86574acf
1 changed files with 5 additions and 1 deletions
|
|
@ -31,7 +31,11 @@ class PreviewManager implements IPreview {
|
|||
*/
|
||||
public function __construct(\OCP\IConfig $config) {
|
||||
$this->config = $config;
|
||||
$this->registerCoreProviders();
|
||||
|
||||
if ($this->config->getSystemValue('enable_previews', true)) {
|
||||
// Register the default providers like txt, image, ...
|
||||
$this->registerCoreProviders();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue