Fix invalid length and invalid chars case
parent
cedfd7a73c
commit
1304fab237
|
@ -81,8 +81,8 @@ impl Game {
|
||||||
(_, _) => InsertionStatus::Ok,
|
(_, _) => InsertionStatus::Ok,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
(0..=5, _, &GameStatus::Playing, true) => InsertionStatus::LengthError,
|
|
||||||
(0..=5, 5, &GameStatus::Playing, false) => InsertionStatus::InvalidChar,
|
(0..=5, 5, &GameStatus::Playing, false) => InsertionStatus::InvalidChar,
|
||||||
|
(0..=5, _, &GameStatus::Playing, _) => InsertionStatus::LengthError,
|
||||||
(_, _, &GameStatus::Win(_) | &GameStatus::Fail, _) => InsertionStatus::GameOver,
|
(_, _, &GameStatus::Win(_) | &GameStatus::Fail, _) => InsertionStatus::GameOver,
|
||||||
_ => InsertionStatus::UnknownError,
|
_ => InsertionStatus::UnknownError,
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue