Skip to content

Commit 7aab8d1

Browse files
committed
[style] Code style fixups in GetWarnings()
1 parent 492c6dc commit 7aab8d1

File tree

1 file changed

+8
-11
lines changed

1 file changed

+8
-11
lines changed

src/warnings.cpp

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -42,31 +42,28 @@ std::string GetWarnings(bool verbose)
4242
{
4343
std::string warnings_concise;
4444
std::string warnings_verbose;
45-
const std::string uiAlertSeperator = "<hr />";
45+
const std::string warning_separator = "<hr />";
4646

4747
LOCK(cs_warnings);
4848

49+
// Pre-release build warning
4950
if (!CLIENT_VERSION_IS_RELEASE) {
5051
warnings_concise = "This is a pre-release test build - use at your own risk - do not use for mining or merchant applications";
5152
warnings_verbose = _("This is a pre-release test build - use at your own risk - do not use for mining or merchant applications").translated;
5253
}
5354

5455
// Misc warnings like out of disk space and clock is wrong
55-
if (strMiscWarning != "")
56-
{
56+
if (strMiscWarning != "") {
5757
warnings_concise = strMiscWarning;
58-
warnings_verbose += (warnings_verbose.empty() ? "" : uiAlertSeperator) + strMiscWarning;
58+
warnings_verbose += (warnings_verbose.empty() ? "" : warning_separator) + strMiscWarning;
5959
}
6060

61-
if (fLargeWorkForkFound)
62-
{
61+
if (fLargeWorkForkFound) {
6362
warnings_concise = "Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.";
64-
warnings_verbose += (warnings_verbose.empty() ? "" : uiAlertSeperator) + _("Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.").translated;
65-
}
66-
else if (fLargeWorkInvalidChainFound)
67-
{
63+
warnings_verbose += (warnings_verbose.empty() ? "" : warning_separator) + _("Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.").translated;
64+
} else if (fLargeWorkInvalidChainFound) {
6865
warnings_concise = "Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.";
69-
warnings_verbose += (warnings_verbose.empty() ? "" : uiAlertSeperator) + _("Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.").translated;
66+
warnings_verbose += (warnings_verbose.empty() ? "" : warning_separator) + _("Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.").translated;
7067
}
7168

7269
if (verbose) return warnings_verbose;

0 commit comments

Comments
 (0)