aboutsummaryrefslogtreecommitdiff
path: root/src/qt
diff options
context:
space:
mode:
authorHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2021-08-06 21:51:57 +0300
committerHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2021-08-06 22:08:24 +0300
commit77a90f03acd551bcc538f6728939cc2ed8c6a3c4 (patch)
tree9901e842354ac2450b6b7ba724c208089efae8f9 /src/qt
parent6a5ccd65c704253b7442b54064f5ba281c34fd26 (diff)
refactor: Move MakeUnorderedList into util/string.h to make it reusable
Diffstat (limited to 'src/qt')
-rw-r--r--src/qt/bitcoin.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp
index ababab31d3..09f453363d 100644
--- a/src/qt/bitcoin.cpp
+++ b/src/qt/bitcoin.cpp
@@ -28,6 +28,7 @@
#include <qt/utilitydialog.h>
#include <qt/winshutdownmonitor.h>
#include <uint256.h>
+#include <util/string.h>
#include <util/system.h>
#include <util/threadnames.h>
#include <util/translation.h>
@@ -144,11 +145,6 @@ static void initTranslations(QTranslator &qtTranslatorBase, QTranslator &qtTrans
QApplication::installTranslator(&translator);
}
-static std::string MakeUnorderedList(const std::vector<std::string>& errors)
-{
- return Join(errors, "\n", [](const std::string& error) { return "- " + error; });
-}
-
static bool InitSettings()
{
if (!gArgs.GetSettingsPath()) {
@@ -186,7 +182,7 @@ static bool InitSettings()
/*: Explanatory text shown on startup when the settings file could not be written.
Prompts user to check that we have the ability to write to the file.
Explains that the user has the option of running without a settings file.*/
- messagebox.setInformativeText(QObject::tr("A fatal error occured. Check that settings file is writable, or try running with -nosettings."));
+ messagebox.setInformativeText(QObject::tr("A fatal error occurred. Check that settings file is writable, or try running with -nosettings."));
messagebox.setDetailedText(QString::fromStdString(MakeUnorderedList(errors)));
messagebox.setTextFormat(Qt::PlainText);
messagebox.setDefaultButton(QMessageBox::Ok);