message: refactor: Fix formatting of timedata.cpp
diff: #include <util/translation.h>
  #include <warnings.h>
  -
  static Mutex g_timeoffset_mutex;
  static int64_t nTimeOffset GUARDED_BY(g_timeoffset_mutex) = 0;
  @@ -71,31 +70,25 @@ void AddTimeData(const CNetAddr& ip, int64_t nOffsetSample)
  // So we should hold off on fixing this and clean it up as part of
  // a timing cleanup that strengthens it in a number of other ways.
  //
  - if (vTimeOffsets.size() >= 5 && vTimeOffsets.size() % 2 == 1)
  - {
  + if (vTimeOffsets.size() >= 5 && vTimeOffsets.size() % 2 == 1) {
  int64_t nMedian = vTimeOffsets.median();
  std::vector<int64_t> vSorted = vTimeOffsets.sorted();
  // Only let other nodes change our time by so much
  - int64_t max_adjustment = std::max<int64_t>(0, gArgs.GetArg("-maxtimeadjustment", DEFAULT_MAX_TIME_ADJUSTMENT));
  - if (nMedian >= -max_adjustment && nMedian <= max_adjustment) {
  + if (abs64(nMedian) <= std::max<int64_t>(0, gArgs.GetArg("-maxtimeadjustment", DEFAULT_MAX_TIME_ADJUSTMENT))) {
  nTimeOffset = nMedian;
  - }
  - else
  - {
  + } else {
  nTimeOffset = 0;
  static bool fDone;
  - if (!fDone)
  - {
  + if (!fDone) {
  // If nobody has a time different than ours but within 5 minutes of ours, give a warning
  bool fMatch = false;
  for (const int64_t nOffset : vSorted) {
  - if (nOffset != 0 && nOffset > -5 * 60 && nOffset < 5 * 60)
  - fMatch = true;
  + if (nOffset != 0 && abs64(nOffset) < 5 * 60) fMatch = true;
  + }
  }
  - if (!fMatch)
  - {
  + if (!fMatch) {
  fDone = true;
  bilingual_str strMessage = strprintf(_("Please check that your computer's date and time are correct! If your clock is wrong, %s will not work properly."), PACKAGE_NAME);
  SetMiscWarning(strMessage.translated);
  @@ -109,7 +102,6 @@ void AddTimeData(const CNetAddr& ip, int64_t nOffsetSample)
  LogPrint(BCLog::NET, "%+d ", n); /* Continued */
  }
  LogPrint(BCLog::NET, "| "); /* Continued */
  -
  LogPrint(BCLog::NET, "nTimeOffset = %+d (%+d minutes)\n", nTimeOffset, nTimeOffset / 60);
  }
  }
  