Simplify (remove duplicate spaces) text messages

This commit is contained in:
Klaus Basan
2018-01-21 01:49:02 +01:00
parent 2da4b2719a
commit a3bbb72185
4 changed files with 6 additions and 6 deletions

View File

@@ -264,10 +264,10 @@ namespace BlackCore
CLogMessage(this).validationError("Incorrect message");
return false;
}
QString receiver = parser.part(1).trimmed(); // receiver
// set receiver
CSimulatedAircraft ownAircraft(this->getIContextOwnAircraft()->getOwnAircraft());
const QString receiver = parser.part(1).trimmed(); // receiver
const CSimulatedAircraft ownAircraft(this->getIContextOwnAircraft()->getOwnAircraft());
if (ownAircraft.getCallsign().isEmpty())
{
CLogMessage(this).validationError("No own callsign");

View File

@@ -1108,7 +1108,7 @@ namespace BlackCore
// Wait maximum 3 seconds for the reply and release as text message after
if (pendingQuery.m_queryTime.secsTo(QDateTime::currentDateTimeUtc()) > 3)
{
QString atisMessage(pendingQuery.m_atisMessage.join(QChar::LineFeed));
const QString atisMessage(pendingQuery.m_atisMessage.join(QChar::LineFeed));
CTextMessage tm(atisMessage, sender, receiver);
tm.setCurrentUtcTime();
consolidateTextMessage(tm);