17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-31 12:19:06 +01:00

refactor(sonar): add braces around nested if-else (cpp:S5261)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
jerrrrycho
2026-10-10 16:25:40 +02:00
parent 24425d222f
commit 0bf013fef9
3 changed files with 12 additions and 0 deletions

View File

@@ -4544,6 +4544,7 @@ void TMoverParameters::UpdatePipePressure(double dt)
}
if (dpMainValve < 0) // && (PipePressureVal > 0.01) //50
{
if (Compressor > ScndPipePress)
{
CompressedVolume = CompressedVolume + dpMainValve / 1500.0;
@@ -4551,6 +4552,7 @@ void TMoverParameters::UpdatePipePressure(double dt)
}
else
Pipe2->Flow(dpMainValve);
}
}
// ulepszony hamulec bezp.
@@ -4625,10 +4627,12 @@ void TMoverParameters::UpdatePipePressure(double dt)
//(Hamulec as TLSt).SetLBP(LocBrakePress);
Hamulec->SetLBP(LocBrakePress);
if (BrakeValve == TBrakeValve::EStED)
{
if (MBPM < 2)
Hamulec->PLC(MaxBrakePress[LoadFlag]);
else
Hamulec->PLC(TotalMass - Mred);
}
break;
}