#include <QLoggingCategory>
+#include "configfile.h"
+
#include "fileprovider.h"
namespace OCC {
Q_ASSERT(!_instance);
if (!fileProviderAvailable()) {
- qCDebug(lcMacFileProvider) << "File provider system is not available on this version of macOS.";
+ qCInfo(lcMacFileProvider) << "File provider system is not available on this version of macOS.";
+ deleteLater();
+ return;
+ } else if (!ConfigFile().macFileProviderModuleEnabled()) {
+ qCInfo(lcMacFileProvider) << "File provider module is not enabled in application config.";
+ deleteLater();
return;
}
- qCDebug(lcMacFileProvider) << "Initialising file provider domain manager.";
+ qCInfo(lcMacFileProvider) << "Initialising file provider domain manager.";
_domainManager = std::make_unique<FileProviderDomainManager>(new FileProviderDomainManager(this));
if (_domainManager) {
FileProvider *FileProvider::instance()
{
if (!fileProviderAvailable()) {
+ qCInfo(lcMacFileProvider) << "File provider system is not available on this version of macOS.";
+ return nullptr;
+ } else if (!ConfigFile().macFileProviderModuleEnabled()) {
+ qCInfo(lcMacFileProvider) << "File provider module is not enabled in application config.";
return nullptr;
}