diff --git a/lib/main.dart b/lib/main.dart index 94d6618..d345470 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -48,8 +48,8 @@ void main() async { print('WireGuard is installed.'); } - await WireGuardService.initializeServer(); await ServerService.registerServer(); + await WireGuardService.initializeServer(); initHeartbeat(); if (!Platform.isMacOS) { diff --git a/lib/services/server_service.dart b/lib/services/server_service.dart index 3dfb441..b507012 100644 --- a/lib/services/server_service.dart +++ b/lib/services/server_service.dart @@ -23,7 +23,7 @@ class ServerService { "last_heartbeat": DateTime.now().toUtc().toIso8601String(), "host_ip": ip, "geolocation": { - "country": geolocationData.country, + "country": geolocationData.countryName, "country_code": geolocationData.countryCode, "city": geolocationData.city, "coords": [