Skip to content

Commit 1dd719f

Browse files
committed
use auto load plugins in delayed node
1 parent 7089d2a commit 1dd719f

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

programs/delayed_node/main.cpp

+3-10
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,9 @@ int main(int argc, char** argv) {
7070

7171
bpo::variables_map options;
7272

73-
auto delayed_plug = node->register_plugin<delayed_node::delayed_node_plugin>();
74-
auto history_plug = node->register_plugin<account_history::account_history_plugin>();
75-
auto market_history_plug = node->register_plugin<market_history::market_history_plugin>();
73+
auto delayed_plug = node->register_plugin<delayed_node::delayed_node_plugin>(true);
74+
auto history_plug = node->register_plugin<account_history::account_history_plugin>(true);
75+
auto market_history_plug = node->register_plugin<market_history::market_history_plugin>(true);
7676

7777
try
7878
{
@@ -88,13 +88,6 @@ int main(int argc, char** argv) {
8888
return 1;
8989
}
9090

91-
std::set<std::string> plugins = {"delayed_node", "account_history", "market_history"};
92-
std::for_each(plugins.begin(), plugins.end(), [node](const std::string& plug) mutable {
93-
if (!plug.empty()) {
94-
node->enable_plugin(plug);
95-
}
96-
});
97-
9891
if( options.count("help") )
9992
{
10093
std::cout << app_options << "\n";

0 commit comments

Comments
 (0)