mirror of
https://github.com/wger-project/flutter.git
synced 2026-11-28 17:08:29 +01:00
The app already checks a minimum app version from the server, but the opposite wasn't true — an app could connect to an older server with a different API without any warning. This adds a MIN_SERVER_VERSION constant in the app that is checked against the server version (already fetched in AuthProvider) during both login() and tryAutoLogin(). If the server is too old, the user is silently logged out and returned to the auth screen to connect to a compatible server. Includes unit tests for version string parsing (including Python-style pre-release versions like '2.5.0a2'). Closes #<issue-number>