File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -1044,12 +1044,12 @@ bool AppInitParameterInteraction(const ArgsManager& args)
10441044 if (args.GetBoolArg (" -peerbloomfilters" , DEFAULT_PEERBLOOMFILTERS))
10451045 g_local_services = ServiceFlags (g_local_services | NODE_BLOOM);
10461046
1047- if (args.IsArgSet (" -test" )) {
1047+ const std::vector<std::string> test_options = args.GetArgs (" -test" );
1048+ if (!test_options.empty ()) {
10481049 if (chainparams.GetChainType () != ChainType::REGTEST) {
10491050 return InitError (Untranslated (" -test=<option> can only be used with regtest" ));
10501051 }
1051- const std::vector<std::string> options = args.GetArgs (" -test" );
1052- for (const std::string& option : options) {
1052+ for (const std::string& option : test_options) {
10531053 auto it = std::find_if (TEST_OPTIONS_DOC.begin (), TEST_OPTIONS_DOC.end (), [&option](const std::string& doc_option) {
10541054 size_t pos = doc_option.find (" (" );
10551055 return (pos != std::string::npos) && (doc_option.substr (0 , pos) == option);
You can’t perform that action at this time.
0 commit comments