Better reporting for missing [node_db]

This commit is contained in:
Vinnie Falco
2013-08-09 14:23:39 -07:00
parent 974ff8f07c
commit 0f3edbbf11

View File

@@ -447,6 +447,11 @@ public:
//------------------------------------------------------------------------------
static void missing_backend ()
{
fatal_error ("Your rippled.cfg is missing a [node_db] entry, please see the rippled-example.cfg file!");
}
static NodeStore::Backend* createBackend (
Parameters const& parameters, Scheduler& scheduler = getSynchronousScheduler ())
{
@@ -473,12 +478,12 @@ public:
}
else
{
Throw (std::runtime_error ("unknown backend type"));
missing_backend ();
}
}
else
{
Throw (std::runtime_error ("missing backend type"));
missing_backend ();
}
return backend;