Commit f43df9d3 authored by Nguyen, Thien Minh's avatar Nguyen, Thien Minh
Browse files

Code format


Signed-off-by: Nguyen, Thien Minh's avatarThien Nguyen <nguyentm@ornl.gov>
parents 1df2b8ee ac7b93df
...@@ -184,20 +184,18 @@ XACCLogger::XACCLogger() ...@@ -184,20 +184,18 @@ XACCLogger::XACCLogger()
useCout(RuntimeOptions::instance()->exists("use-cout")), useCout(RuntimeOptions::instance()->exists("use-cout")),
useFile(RuntimeOptions::instance()->exists("use-file")) { useFile(RuntimeOptions::instance()->exists("use-file")) {
// Create a std::out logger instance // Create a std::out logger instance
{ std::string loggerName = "xacc-logger";
std::string loggerName = "xacc-logger"; if (RuntimeOptions::instance()->exists("logger-name")) {
if (RuntimeOptions::instance()->exists("logger-name")) { loggerName = (*RuntimeOptions::instance())["logger-name"];
loggerName = (*RuntimeOptions::instance())["logger-name"];
}
auto _log = spdlog::get(loggerName);
if (_log) {
stdOutLogger = _log;
} else {
stdOutLogger = spdlog::stdout_logger_mt(loggerName);
}
stdOutLogger->set_level(spdlog::level::info);
} }
auto _log = spdlog::get(loggerName);
if (_log) {
stdOutLogger = _log;
} else {
stdOutLogger = spdlog::stdout_logger_mt(loggerName);
}
stdOutLogger->set_level(spdlog::level::info);
} }
void XACCLogger::createFileLogger() { void XACCLogger::createFileLogger() {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment