Skip to content

Commit

Permalink
feat: configure formatting with config
Browse files Browse the repository at this point in the history
  • Loading branch information
3Hren committed Aug 22, 2016
1 parent e7abbdd commit 7c6761d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/formatter/json.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -522,6 +522,12 @@ auto factory<json_t>::from(const config::node_t& config) const ->
});
}

if (auto formatting = config["formatting"]) {
formatting.each_map([&](const std::string& key, const config::node_t& value) {
builder.format(key, value.to_string());
});
}

if (auto routing = config["routing"]) {
routing.each_map([&](const std::string& key, const config::node_t& value) {
try {
Expand Down

0 comments on commit 7c6761d

Please sign in to comment.