A helper function to ensure that configuration is not accessed before it is initialized (was formerly static)
| 126 | std::unique_ptr<Configuration> pconfig; |
| 127 | /// A helper function to ensure that configuration is not accessed before it is initialized (was formerly static) |
| 128 | Configuration* _get_config() { |
| 129 | if (!pconfig) { |
| 130 | pconfig = std::make_unique<Configuration>(); |
| 131 | } |
| 132 | return pconfig.get(); |
| 133 | } |
| 134 | |
| 135 | void set_config_bool(configuration_keys key, bool val) { |
| 136 | _get_config()->get_item(key).set_bool(val); |
no test coverage detected