mirror of
https://github.com/oxen-io/lokinet.git
synced 2024-11-11 07:10:36 +00:00
default to default data dir given by params instead
This commit is contained in:
parent
1cbf50296c
commit
c4b5b641bb
@ -71,14 +71,13 @@ namespace llarp
|
||||
|
||||
conf.defineOption<std::string>("router", "nickname", false, "", AssignmentAcceptor(m_nickname));
|
||||
|
||||
conf.defineOption<std::string>(
|
||||
"router", "data-dir", false, GetDefaultDataDir(), [this](std::string arg) {
|
||||
fs::path dir = arg;
|
||||
if (not fs::exists(dir))
|
||||
conf.defineOption<fs::path>(
|
||||
"router", "data-dir", false, params.defaultDataDir, [this](fs::path arg) {
|
||||
if (not fs::exists(arg))
|
||||
throw std::runtime_error(
|
||||
stringify("Specified [router]:data-dir ", arg, " does not exist"));
|
||||
|
||||
m_dataDir = std::move(dir);
|
||||
m_dataDir = std::move(arg);
|
||||
});
|
||||
|
||||
conf.defineOption<std::string>("router", "public-address", false, "", [this](std::string arg) {
|
||||
|
Loading…
Reference in New Issue
Block a user