Issue #74 Style: remove egregious redundancy in CCoreFacadeConfig

This commit is contained in:
Mat Sutcliffe
2020-08-16 15:27:08 +01:00
parent 8ce3fe7178
commit bd6b5c456c

View File

@@ -58,25 +58,21 @@ namespace BlackCore
CCoreFacadeConfig CCoreFacadeConfig::forCoreAllLocalInDBus(const QString &dbusBootstrapAddress) CCoreFacadeConfig CCoreFacadeConfig::forCoreAllLocalInDBus(const QString &dbusBootstrapAddress)
{ {
const CCoreFacadeConfig cfg(CCoreFacadeConfig::LocalInDBusServer, dbusBootstrapAddress); return { LocalInDBusServer, dbusBootstrapAddress };
return cfg;
} }
CCoreFacadeConfig CCoreFacadeConfig::local(const QString &dbusBootstrapAddress) CCoreFacadeConfig CCoreFacadeConfig::local(const QString &dbusBootstrapAddress)
{ {
const CCoreFacadeConfig cfg = CCoreFacadeConfig(CCoreFacadeConfig(CCoreFacadeConfig::Local, dbusBootstrapAddress)); return { Local, dbusBootstrapAddress };
return cfg;
} }
CCoreFacadeConfig CCoreFacadeConfig::remote(const QString &dbusBootstrapAddress) CCoreFacadeConfig CCoreFacadeConfig::remote(const QString &dbusBootstrapAddress)
{ {
CCoreFacadeConfig cfg = CCoreFacadeConfig(CCoreFacadeConfig(CCoreFacadeConfig::Remote, dbusBootstrapAddress)); return { Remote, dbusBootstrapAddress };
return cfg;
} }
CCoreFacadeConfig CCoreFacadeConfig::allEmpty() CCoreFacadeConfig CCoreFacadeConfig::allEmpty()
{ {
CCoreFacadeConfig cfg = CCoreFacadeConfig(); return {};
return cfg;
} }
} // namespace } // namespace