Cleanup: simplify some boolean expressions

This commit is contained in:
Rubidium
2021-06-16 23:21:21 +02:00
committed by rubidium42
parent 357af686dc
commit 281a65b3e1
9 changed files with 17 additions and 25 deletions

View File

@@ -956,9 +956,7 @@ static inline bool IsSavegameVersionUntil(SaveLoadVersion major)
static inline bool SlIsObjectCurrentlyValid(SaveLoadVersion version_from, SaveLoadVersion version_to)
{
extern const SaveLoadVersion SAVEGAME_VERSION;
if (SAVEGAME_VERSION < version_from || SAVEGAME_VERSION >= version_to) return false;
return true;
return version_from <= SAVEGAME_VERSION && SAVEGAME_VERSION < version_to;
}
/**