Fix logical operator (#1318)

That `if` should return `true` when both conditions are met (pirep not accepted and not rejected yet), so **AND** must be used there ;) Sorry for the trouble.

Now it works and listens more carefully.
This commit is contained in:
B.Fatih KOZ
2021-09-24 00:07:38 +03:00
committed by GitHub
parent 14e33574fc
commit f99af4cfc3

View File

@@ -479,7 +479,7 @@ class PirepService extends Service
$pirep->refresh();
// Figure out what pirep state should be, if nothing provided yet.
if ($pirep->state != PirepState::ACCEPTED || $pirep->state != PirepState::REJECTED) {
if ($pirep->state != PirepState::ACCEPTED && $pirep->state != PirepState::REJECTED) {
$default_state = PirepState::PENDING;
} else {
$default_state = $pirep->state;